summaryrefslogtreecommitdiffstats
path: root/src/test/ui/coherence/coherence-vec-local-2.rs
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--src/test/ui/coherence/coherence-vec-local-2.rs14
1 files changed, 14 insertions, 0 deletions
diff --git a/src/test/ui/coherence/coherence-vec-local-2.rs b/src/test/ui/coherence/coherence-vec-local-2.rs
new file mode 100644
index 000000000..47df06bac
--- /dev/null
+++ b/src/test/ui/coherence/coherence-vec-local-2.rs
@@ -0,0 +1,14 @@
+// Test that a local, generic type appearing within a
+// *non-fundamental* remote type like `Vec` is not considered local.
+
+// aux-build:coherence_lib.rs
+
+extern crate coherence_lib as lib;
+use lib::Remote;
+
+struct Local<T>(T);
+
+impl<T> Remote for Vec<Local<T>> { }
+//~^ ERROR E0117
+
+fn main() { }