summary refs log tree commit diff
path: root/src/test/ui/closures/closure-array-break-length.rs
blob: a7f16d70ba8600d083f246acc285f0f9c6fb24d7 (plain)
1
2
3
4
5
6
7
8
9
fn main() {
    |_: [_; continue]| {}; //~ ERROR: `continue` outside of loop

    while |_: [_; continue]| {} {} //~ ERROR: `continue` outside of loop
    //~^ ERROR mismatched types

    while |_: [_; break]| {} {} //~ ERROR: `break` outside of loop
    //~^ ERROR mismatched types
}