|
1 | 1 | error: `$ty:ty` is followed by `<`, which is not allowed for `ty` fragments
|
2 |
| - --> $DIR/macro-input-future-proofing.rs:14:13 |
| 2 | + --> $DIR/macro-input-future-proofing.rs:5:13 |
3 | 3 | |
|
4 | 4 | LL | ($ty:ty <) => (); //~ ERROR `$ty:ty` is followed by `<`, which is not allowed for `ty`
|
5 | 5 | | ^ not allowed after `ty` fragments
|
6 | 6 | |
|
7 | 7 | = note: allowed there are: `,`, `{`, `[`, `=>`, `>`, `=`, `:`, `;`, `|`, `as` or `where`
|
8 | 8 |
|
9 | 9 | error: `$ty:ty` is followed by `<`, which is not allowed for `ty` fragments
|
10 |
| - --> $DIR/macro-input-future-proofing.rs:15:13 |
| 10 | + --> $DIR/macro-input-future-proofing.rs:6:13 |
11 | 11 | |
|
12 | 12 | LL | ($ty:ty < foo ,) => (); //~ ERROR `$ty:ty` is followed by `<`, which is not allowed for `ty`
|
13 | 13 | | ^ not allowed after `ty` fragments
|
14 | 14 | |
|
15 | 15 | = note: allowed there are: `,`, `{`, `[`, `=>`, `>`, `=`, `:`, `;`, `|`, `as` or `where`
|
16 | 16 |
|
17 | 17 | error: `$pa:pat` is followed by `>`, which is not allowed for `pat` fragments
|
18 |
| - --> $DIR/macro-input-future-proofing.rs:21:14 |
| 18 | + --> $DIR/macro-input-future-proofing.rs:12:14 |
19 | 19 | |
|
20 | 20 | LL | ($pa:pat >) => (); //~ ERROR `$pa:pat` is followed by `>`, which is not allowed for `pat`
|
21 | 21 | | ^ not allowed after `pat` fragments
|
22 | 22 | |
|
23 | 23 | = note: allowed there are: `=>`, `,`, `=`, `|`, `if` or `in`
|
24 | 24 |
|
25 | 25 | error: `$pa:pat` is followed by `$pb:pat`, which is not allowed for `pat` fragments
|
26 |
| - --> $DIR/macro-input-future-proofing.rs:23:14 |
| 26 | + --> $DIR/macro-input-future-proofing.rs:14:14 |
27 | 27 | |
|
28 | 28 | LL | ($pa:pat $pb:pat $ty:ty ,) => ();
|
29 | 29 | | ^^^^^^^ not allowed after `pat` fragments
|
30 | 30 | |
|
31 | 31 | = note: allowed there are: `=>`, `,`, `=`, `|`, `if` or `in`
|
32 | 32 |
|
33 | 33 | error: `$pb:pat` is followed by `$ty:ty`, which is not allowed for `pat` fragments
|
34 |
| - --> $DIR/macro-input-future-proofing.rs:23:22 |
| 34 | + --> $DIR/macro-input-future-proofing.rs:14:22 |
35 | 35 | |
|
36 | 36 | LL | ($pa:pat $pb:pat $ty:ty ,) => ();
|
37 | 37 | | ^^^^^^ not allowed after `pat` fragments
|
38 | 38 | |
|
39 | 39 | = note: allowed there are: `=>`, `,`, `=`, `|`, `if` or `in`
|
40 | 40 |
|
41 | 41 | error: `$ty:ty` is followed by `-`, which is not allowed for `ty` fragments
|
42 |
| - --> $DIR/macro-input-future-proofing.rs:26:13 |
| 42 | + --> $DIR/macro-input-future-proofing.rs:17:13 |
43 | 43 | |
|
44 | 44 | LL | ($ty:ty -) => (); //~ ERROR `$ty:ty` is followed by `-`
|
45 | 45 | | ^ not allowed after `ty` fragments
|
46 | 46 | |
|
47 | 47 | = note: allowed there are: `,`, `{`, `[`, `=>`, `>`, `=`, `:`, `;`, `|`, `as` or `where`
|
48 | 48 |
|
49 | 49 | error: `$b:ty` is followed by `-`, which is not allowed for `ty` fragments
|
50 |
| - --> $DIR/macro-input-future-proofing.rs:27:19 |
| 50 | + --> $DIR/macro-input-future-proofing.rs:18:19 |
51 | 51 | |
|
52 | 52 | LL | ($a:ty, $b:ty -) => (); //~ ERROR `$b:ty` is followed by `-`
|
53 | 53 | | ^ not allowed after `ty` fragments
|
54 | 54 | |
|
55 | 55 | = note: allowed there are: `,`, `{`, `[`, `=>`, `>`, `=`, `:`, `;`, `|`, `as` or `where`
|
56 | 56 |
|
57 | 57 | error: `$ty:ty` is followed by `-`, which is not allowed for `ty` fragments
|
58 |
| - --> $DIR/macro-input-future-proofing.rs:28:7 |
| 58 | + --> $DIR/macro-input-future-proofing.rs:19:7 |
59 | 59 | |
|
60 | 60 | LL | ($($ty:ty)-+) => (); //~ ERROR `$ty:ty` is followed by `-`, which is not allowed for `ty`
|
61 | 61 | | ^^^^^^^^ not allowed after `ty` fragments
|
62 | 62 | |
|
63 | 63 | = note: allowed there are: `,`, `{`, `[`, `=>`, `>`, `=`, `:`, `;`, `|`, `as` or `where`
|
64 | 64 |
|
65 | 65 | error: `$a:expr` is followed by `$b:tt`, which is not allowed for `expr` fragments
|
66 |
| - --> $DIR/macro-input-future-proofing.rs:29:17 |
| 66 | + --> $DIR/macro-input-future-proofing.rs:20:17 |
67 | 67 | |
|
68 | 68 | LL | ( $a:expr $($b:tt)* ) => { };
|
69 | 69 | | ^^^^^ not allowed after `expr` fragments
|
70 | 70 | |
|
71 | 71 | = note: allowed there are: `;`, `=>` or `,`
|
72 | 72 |
|
73 | 73 | error: `$a:expr` is followed by `$b:tt`, which is not allowed for `expr` fragments
|
74 |
| - --> $DIR/macro-input-future-proofing.rs:31:21 |
| 74 | + --> $DIR/macro-input-future-proofing.rs:22:21 |
75 | 75 | |
|
76 | 76 | LL | ( $($a:expr)* $($b:tt)* ) => { };
|
77 | 77 | | ^^^^^ not allowed after `expr` fragments
|
78 | 78 | |
|
79 | 79 | = note: allowed there are: `;`, `=>` or `,`
|
80 | 80 |
|
81 | 81 | error: `$a:expr` may be followed by `$b:tt`, which is not allowed for `expr` fragments
|
82 |
| - --> $DIR/macro-input-future-proofing.rs:34:22 |
| 82 | + --> $DIR/macro-input-future-proofing.rs:26:22 |
83 | 83 | |
|
84 | 84 | LL | ( $($a:expr),* $($b:tt)* ) => { };
|
85 | 85 | | ^^^^^ not allowed after `expr` fragments
|
86 | 86 | |
|
87 | 87 | = note: allowed there are: `;`, `=>` or `,`
|
88 | 88 |
|
89 | 89 | warning: `$a:expr` is followed (through repetition) by itself, which is not allowed for `expr` fragments
|
90 |
| - --> $DIR/macro-input-future-proofing.rs:31:9 |
| 90 | + --> $DIR/macro-input-future-proofing.rs:22:9 |
91 | 91 | |
|
92 | 92 | LL | ( $($a:expr)* $($b:tt)* ) => { };
|
93 | 93 | | ^^^^^^^ this fragment is followed by itself without a valid separator
|
94 | 94 | |
|
95 |
| - = note: #[warn(incorrect_macro_fragment_repetition)] on by default |
| 95 | +note: lint level defined here |
| 96 | + --> $DIR/macro-input-future-proofing.rs:2:9 |
| 97 | + | |
| 98 | +LL | #![warn(incorrect_macro_fragment_repetition)] |
| 99 | + | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ |
| 100 | + = warning: this was previously accepted by the compiler but is being phased out; it will become a hard error in a future release! |
| 101 | + = note: for more information, see issue #56575 <https://github.com/rust-lang/rust/issues/56575> |
96 | 102 | = note: allowed there are: `;`, `=>` or `,`
|
97 | 103 | help: add a valid separator for the repetition to be unambiguous, for example
|
98 | 104 | |
|
|
0 commit comments