about summary refs log tree commit diff
path: root/src/test/parse-fail
diff options
context:
space:
mode:
authorZack M. Davis <code@zackmdavis.net>2018-03-11 00:04:15 -0800
committerZack M. Davis <code@zackmdavis.net>2018-03-11 00:12:06 -0800
commit9b599856a4b7e375e4e54eb759c250be969f5562 (patch)
tree57b2184cdf8b196487c70d2b696ae8d40f1a9a61 /src/test/parse-fail
parent2f0e6a3ba585e00205805d6cb9fdcbe4b1d1be63 (diff)
downloadrust-9b599856a4b7e375e4e54eb759c250be969f5562.tar.gz
rust-9b599856a4b7e375e4e54eb759c250be969f5562.zip
in which some labels and notes are upgraded to structured suggestions
(Meanwhile, a couple of parse-fail tests are moved to UI tests so that
the reader can see the new output, and an existing UI test is given a
more evocative name.)
Diffstat (limited to 'src/test/parse-fail')
-rw-r--r--src/test/parse-fail/match-refactor-to-expr.rs22
-rw-r--r--src/test/parse-fail/pub-macro-rules.rs27
2 files changed, 0 insertions, 49 deletions
diff --git a/src/test/parse-fail/match-refactor-to-expr.rs b/src/test/parse-fail/match-refactor-to-expr.rs
deleted file mode 100644
index e2fee1d1895..00000000000
--- a/src/test/parse-fail/match-refactor-to-expr.rs
+++ /dev/null
@@ -1,22 +0,0 @@
-// Copyright 2015 The Rust Project Developers. See the COPYRIGHT
-// file at the top-level directory of this distribution and at
-// http://rust-lang.org/COPYRIGHT.
-//
-// Licensed under the Apache License, Version 2.0 <LICENSE-APACHE or
-// http://www.apache.org/licenses/LICENSE-2.0> or the MIT license
-// <LICENSE-MIT or http://opensource.org/licenses/MIT>, at your
-// option. This file may not be copied, modified, or distributed
-// except according to those terms.
-
-// compile-flags: -Z parse-only
-
-fn main() {
-    let foo =
-        match //~ NOTE did you mean to remove this `match` keyword?
-        Some(4).unwrap_or_else(5)
-        //~^ NOTE expected one of `.`, `?`, `{`, or an operator here
-        ; //~ NOTE unexpected token
-        //~^ ERROR expected one of `.`, `?`, `{`, or an operator, found `;`
-
-    println!("{}", foo)
-}
diff --git a/src/test/parse-fail/pub-macro-rules.rs b/src/test/parse-fail/pub-macro-rules.rs
deleted file mode 100644
index 93b992f2f8a..00000000000
--- a/src/test/parse-fail/pub-macro-rules.rs
+++ /dev/null
@@ -1,27 +0,0 @@
-// Copyright 2015 The Rust Project Developers. See the COPYRIGHT
-// file at the top-level directory of this distribution and at
-// http://rust-lang.org/COPYRIGHT.
-//
-// Licensed under the Apache License, Version 2.0 <LICENSE-APACHE or
-// http://www.apache.org/licenses/LICENSE-2.0> or the MIT license
-// <LICENSE-MIT or http://opensource.org/licenses/MIT>, at your
-// option. This file may not be copied, modified, or distributed
-// except according to those terms.
-
-#[macro_use] mod bleh {
-    pub macro_rules! foo { //~ ERROR can't qualify macro_rules invocation with `pub`
-    //~^ HELP did you mean #[macro_export]?
-        ($n:ident) => (
-            fn $n () -> i32 {
-                1
-            }
-        )
-    }
-
-}
-
-foo!(meh);
-
-fn main() {
-    println!("{}", meh());
-}