summary refs log tree commit diff
path: root/src/test/compile-fail/issue-17431-4.rs
diff options
context:
space:
mode:
Diffstat (limited to 'src/test/compile-fail/issue-17431-4.rs')
-rw-r--r--src/test/compile-fail/issue-17431-4.rs4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/test/compile-fail/issue-17431-4.rs b/src/test/compile-fail/issue-17431-4.rs
index 1e27f025564..22aaa796ad0 100644
--- a/src/test/compile-fail/issue-17431-4.rs
+++ b/src/test/compile-fail/issue-17431-4.rs
@@ -8,7 +8,9 @@
 // option. This file may not be copied, modified, or distributed
 // except according to those terms.
 
-struct Foo<T> { foo: Option<Option<Foo<T>>> }
+use std::marker;
+
+struct Foo<T> { foo: Option<Option<Foo<T>>>, marker: marker::PhantomData<T> }
 //~^ ERROR illegal recursive struct type; wrap the inner value in a box to make it representable
 
 impl<T> Foo<T> { fn bar(&self) {} }