]> git.lizzy.rs Git - rust.git/blobdiff - src/test/run-pass/issue-3556.rs
test: Automatically remove all `~[T]` from tests.
[rust.git] / src / test / run-pass / issue-3556.rs
index 5a787f8c0eea4a44d7c0e7418278eb4d0246302a..bfdf623efda76e7df7f94ab5faa7a6470b3d62bd 100644 (file)
 
 enum Token {
     Text(@~str),
-    ETag(@~[~str], @~str),
-    UTag(@~[~str], @~str),
-    Section(@~[~str], bool, @~[Token], @~str, @~str, @~str, @~str, @~str),
-    IncompleteSection(@~[~str], bool, @~str, bool),
+    ETag(@Vec<~str> , @~str),
+    UTag(@Vec<~str> , @~str),
+    Section(@Vec<~str> , bool, @Vec<Token> , @~str, @~str, @~str, @~str, @~str),
+    IncompleteSection(@Vec<~str> , bool, @~str, bool),
     Partial(@~str, @~str, @~str),
 }
 
@@ -35,7 +35,7 @@ pub fn main()
 // assert!(check_strs(fmt!("%?", ETag(@~[~"foo"], @~"bar")), "ETag(@~[ ~\"foo\" ], @~\"bar\")"));
 
     let t = Text(@~"foo");
-    let u = Section(@~[~"alpha"], true, @~[t], @~"foo", @~"foo", @~"foo", @~"foo", @~"foo");
+    let u = Section(@vec!(~"alpha"), true, @vec!(t), @~"foo", @~"foo", @~"foo", @~"foo", @~"foo");
     let v = format!("{:?}", u);    // this is the line that causes the seg fault
     assert!(v.len() > 0);
 }