diff options
| author | Jeffrey Seyfried <jeffrey.seyfried@gmail.com> | 2017-02-26 03:25:22 +0000 |
|---|---|---|
| committer | Jeffrey Seyfried <jeffrey.seyfried@gmail.com> | 2017-02-28 22:15:12 +0000 |
| commit | 61a9a14d29529dee188d76dbf5c9faaefa9fce87 (patch) | |
| tree | cec5d4b58fe52015afc4e6b4988995b401214546 /src/test | |
| parent | 7f822c800d6304466be666937539117d95a58022 (diff) | |
| download | rust-61a9a14d29529dee188d76dbf5c9faaefa9fce87.tar.gz rust-61a9a14d29529dee188d76dbf5c9faaefa9fce87.zip | |
Add warning cycle.
Diffstat (limited to 'src/test')
| -rw-r--r-- | src/test/compile-fail/issue-39404.rs | 18 | ||||
| -rw-r--r-- | src/test/compile-fail/macro-match-nonterminal.rs | 3 | ||||
| -rw-r--r-- | src/test/parse-fail/issue-33569.rs | 2 |
3 files changed, 21 insertions, 2 deletions
diff --git a/src/test/compile-fail/issue-39404.rs b/src/test/compile-fail/issue-39404.rs new file mode 100644 index 00000000000..0168ae7d910 --- /dev/null +++ b/src/test/compile-fail/issue-39404.rs @@ -0,0 +1,18 @@ +// Copyright 2017 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. + +#![deny(missing_fragment_specifier)] //~ NOTE lint level defined here + +macro_rules! m { ($i) => {} } +//~^ ERROR missing fragment specifier +//~| WARN previously accepted +//~| NOTE issue #40107 + +fn main() {} diff --git a/src/test/compile-fail/macro-match-nonterminal.rs b/src/test/compile-fail/macro-match-nonterminal.rs index 0af171b43fe..6cca729e2c2 100644 --- a/src/test/compile-fail/macro-match-nonterminal.rs +++ b/src/test/compile-fail/macro-match-nonterminal.rs @@ -8,8 +8,7 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. -macro_rules! test { ($a, //~ ERROR missing fragment - $b) => (()); } //~ ERROR missing fragment +macro_rules! test { ($a, $b) => (()); } //~ ERROR missing fragment fn main() { test!() diff --git a/src/test/parse-fail/issue-33569.rs b/src/test/parse-fail/issue-33569.rs index d72bd8aab89..15d491719a6 100644 --- a/src/test/parse-fail/issue-33569.rs +++ b/src/test/parse-fail/issue-33569.rs @@ -16,3 +16,5 @@ macro_rules! foo { $(x)(y) //~ ERROR expected `*` or `+` } } + +foo!(); |
