rust/src/test/ui/array-break-length.rs
2019-08-21 15:13:13 +03:00

12 lines
255 B
Rust

fn main() {
loop {
|_: [_; break]| {} //~ ERROR: `break` outside of a loop
//~^ ERROR mismatched types
}
loop {
|_: [_; continue]| {} //~ ERROR: `continue` outside of a loop
//~^ ERROR mismatched types
}
}