]> git.lizzy.rs Git - rust.git/blob - src/test/ui/array-break-length.stderr
Auto merge of #65421 - estebank:variants, r=petrochenkov
[rust.git] / src / test / ui / array-break-length.stderr
1 error[E0268]: `break` outside of a loop
2   --> $DIR/array-break-length.rs:3:17
3    |
4 LL |         |_: [_; break]| {}
5    |                 ^^^^^ cannot `break` outside of a loop
6
7 error[E0268]: `continue` outside of a loop
8   --> $DIR/array-break-length.rs:8:17
9    |
10 LL |         |_: [_; continue]| {}
11    |                 ^^^^^^^^ cannot `continue` outside of a loop
12
13 error[E0308]: mismatched types
14   --> $DIR/array-break-length.rs:3:9
15    |
16 LL |         |_: [_; break]| {}
17    |         ^^^^^^^^^^^^^^^^^^ expected (), found closure
18    |
19    = note: expected type `()`
20               found type `[closure@$DIR/array-break-length.rs:3:9: 3:27]`
21
22 error[E0308]: mismatched types
23   --> $DIR/array-break-length.rs:8:9
24    |
25 LL |         |_: [_; continue]| {}
26    |         ^^^^^^^^^^^^^^^^^^^^^ expected (), found closure
27    |
28    = note: expected type `()`
29               found type `[closure@$DIR/array-break-length.rs:8:9: 8:30]`
30
31 error: aborting due to 4 previous errors
32
33 Some errors have detailed explanations: E0268, E0308.
34 For more information about an error, try `rustc --explain E0268`.