]> git.lizzy.rs Git - rust.git/blob - src/test/ui/for-loop-while/label_break_value_invalid.stderr
Auto merge of #106025 - matthiaskrgr:rollup-vz5rqah, r=matthiaskrgr
[rust.git] / src / test / ui / for-loop-while / label_break_value_invalid.stderr
1 error[E0426]: use of undeclared label `'a`
2   --> $DIR/label_break_value_invalid.rs:6:19
3    |
4 LL |             break 'a $val;
5    |                   ^^ undeclared label `'a`
6 ...
7 LL |                 mac2!(2);
8    |                 -------- in this macro invocation
9    |
10    = note: this error originates in the macro `mac2` (in Nightly builds, run with -Z macro-backtrace for more info)
11
12 error[E0426]: use of undeclared label `'a`
13   --> $DIR/label_break_value_invalid.rs:28:19
14    |
15 LL |     let x: u8 = mac3!('b: {
16    |                       -- a label with a similar name is reachable
17 LL |         if true {
18 LL |             break 'a 3;
19    |                   ^^
20    |                   |
21    |                   undeclared label `'a`
22    |                   help: try using similarly named label: `'b`
23
24 error[E0426]: use of undeclared label `'a`
25   --> $DIR/label_break_value_invalid.rs:33:29
26    |
27 LL |     let x: u8 = mac3!(break 'a 4);
28    |                             ^^ undeclared label `'a`
29
30 error: aborting due to 3 previous errors
31
32 For more information about this error, try `rustc --explain E0426`.