summary refs log tree commit diff
path: root/src/test/compile-fail/unsized3.rs
diff options
context:
space:
mode:
Diffstat (limited to 'src/test/compile-fail/unsized3.rs')
-rw-r--r--src/test/compile-fail/unsized3.rs5
1 files changed, 4 insertions, 1 deletions
diff --git a/src/test/compile-fail/unsized3.rs b/src/test/compile-fail/unsized3.rs
index 4fc76c99c60..de1cbab82b2 100644
--- a/src/test/compile-fail/unsized3.rs
+++ b/src/test/compile-fail/unsized3.rs
@@ -10,6 +10,7 @@
 
 // Test sized-ness checking in substitution within fn bodies..
 
+use std::marker;
 
 // Unbounded.
 fn f1<X: ?Sized>(x: &X) {
@@ -20,7 +21,9 @@ fn f2<X>(x: &X) {
 }
 
 // Bounded.
-trait T {}
+trait T {
+    fn foo(&self) { }
+}
 fn f3<X: ?Sized + T>(x: &X) {
     f4::<X>(x);
     //~^ ERROR the trait `core::marker::Sized` is not implemented