summaryrefslogtreecommitdiffstats
path: root/src/test/ui/wf/wf-struct-field.rs
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--src/test/ui/wf/wf-struct-field.rs16
1 files changed, 16 insertions, 0 deletions
diff --git a/src/test/ui/wf/wf-struct-field.rs b/src/test/ui/wf/wf-struct-field.rs
new file mode 100644
index 000000000..63f8b4382
--- /dev/null
+++ b/src/test/ui/wf/wf-struct-field.rs
@@ -0,0 +1,16 @@
+// Test that we check struct fields for WFedness.
+
+#![feature(associated_type_defaults)]
+
+#![allow(dead_code)]
+
+struct IsCopy<T:Copy> {
+ value: T
+}
+
+struct SomeStruct<A> {
+ data: IsCopy<A> //~ ERROR E0277
+}
+
+
+fn main() { }