]> git.lizzy.rs Git - rust.git/blob - src/test/ui/break-while-condition.stderr
Rollup merge of #50919 - frewsxcv:frewsxcv-epsilon, r=steveklabnik
[rust.git] / src / test / ui / break-while-condition.stderr
1 error[E0308]: mismatched types
2   --> $DIR/break-while-condition.rs:19:20
3    |
4 LL |           let _: ! = { //~ ERROR mismatched types
5    |  ____________________^
6 LL | |             'a: while break 'a {};
7 LL | |         };
8    | |_________^ expected !, found ()
9    |
10    = note: expected type `!`
11               found type `()`
12
13 error[E0308]: mismatched types
14   --> $DIR/break-while-condition.rs:26:13
15    |
16 LL |   fn main() {
17    |             - expected `()` because of default return type
18 ...
19 LL | /             while false { //~ ERROR mismatched types
20 LL | |                 break
21 LL | |             }
22    | |_____________^ expected !, found ()
23    |
24    = note: expected type `!`
25               found type `()`
26
27 error[E0308]: mismatched types
28   --> $DIR/break-while-condition.rs:34:13
29    |
30 LL |   fn main() {
31    |             - expected `()` because of default return type
32 ...
33 LL | /             while false { //~ ERROR mismatched types
34 LL | |                 return
35 LL | |             }
36    | |_____________^ expected !, found ()
37    |
38    = note: expected type `!`
39               found type `()`
40
41 error: aborting due to 3 previous errors
42
43 For more information about this error, try `rustc --explain E0308`.