about summary refs log tree commit diff
path: root/src/test/compile-fail/no_send-struct.rs
diff options
context:
space:
mode:
Diffstat (limited to 'src/test/compile-fail/no_send-struct.rs')
-rw-r--r--src/test/compile-fail/no_send-struct.rs9
1 files changed, 6 insertions, 3 deletions
diff --git a/src/test/compile-fail/no_send-struct.rs b/src/test/compile-fail/no_send-struct.rs
index bef70523787..7f16db0ba94 100644
--- a/src/test/compile-fail/no_send-struct.rs
+++ b/src/test/compile-fail/no_send-struct.rs
@@ -8,17 +8,20 @@
 // option. This file may not be copied, modified, or distributed
 // except according to those terms.
 
-use std::marker;
+#![feature(optin_builtin_traits)]
+
+use std::marker::Send;
 
 struct Foo {
     a: isize,
-    ns: marker::NoSend
 }
 
+impl !Send for Foo {}
+
 fn bar<T: Send>(_: T) {}
 
 fn main() {
-    let x = Foo { a: 5, ns: marker::NoSend };
+    let x = Foo { a: 5 };
     bar(x);
     //~^ ERROR the trait `core::marker::Send` is not implemented
 }