summaryrefslogtreecommitdiffstats
path: root/src/test/ui/issues/issue-2590.rs
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--src/test/ui/issues/issue-2590.rs15
1 files changed, 15 insertions, 0 deletions
diff --git a/src/test/ui/issues/issue-2590.rs b/src/test/ui/issues/issue-2590.rs
new file mode 100644
index 000000000..a9a0e5ca4
--- /dev/null
+++ b/src/test/ui/issues/issue-2590.rs
@@ -0,0 +1,15 @@
+struct Parser {
+ tokens: Vec<isize> ,
+}
+
+trait Parse {
+ fn parse(&self) -> Vec<isize> ;
+}
+
+impl Parse for Parser {
+ fn parse(&self) -> Vec<isize> {
+ self.tokens //~ ERROR cannot move out
+ }
+}
+
+fn main() {}