]>
Commit | Line | Data |
---|---|---|
b7449926 | 1 | error[E0308]: mismatched types |
0731742a | 2 | --> $DIR/loop-labeled-break-value.rs:3:29 |
b7449926 | 3 | | |
532ac7d7 | 4 | LL | let _: i32 = loop { break }; |
416331ca XL |
5 | | ^^^^^ |
6 | | | | |
60c5eb7d | 7 | | expected `i32`, found `()` |
416331ca | 8 | | help: give it a value of the expected type: `break 42` |
b7449926 XL |
9 | |
10 | error[E0308]: mismatched types | |
0731742a | 11 | --> $DIR/loop-labeled-break-value.rs:6:37 |
b7449926 | 12 | | |
532ac7d7 | 13 | LL | let _: i32 = 'inner: loop { break 'inner }; |
416331ca XL |
14 | | ^^^^^^^^^^^^ |
15 | | | | |
60c5eb7d | 16 | | expected `i32`, found `()` |
416331ca | 17 | | help: give it a value of the expected type: `break 'inner 42` |
b7449926 XL |
18 | |
19 | error[E0308]: mismatched types | |
0731742a | 20 | --> $DIR/loop-labeled-break-value.rs:9:45 |
b7449926 | 21 | | |
532ac7d7 | 22 | LL | let _: i32 = 'inner2: loop { loop { break 'inner2 } }; |
416331ca XL |
23 | | ^^^^^^^^^^^^^ |
24 | | | | |
60c5eb7d | 25 | | expected `i32`, found `()` |
416331ca | 26 | | help: give it a value of the expected type: `break 'inner2 42` |
b7449926 XL |
27 | |
28 | error: aborting due to 3 previous errors | |
29 | ||
30 | For more information about this error, try `rustc --explain E0308`. |