mirror of
https://github.com/rust-lang/rust
synced 2024-11-05 20:45:15 +00:00
8 lines
304 B
Rust
8 lines
304 B
Rust
fn main() {
|
|
let _ = for _ in 0..1 {
|
|
//~^ NOTE `else` is attached to this loop
|
|
} else {
|
|
//~^ ERROR `for...else` loops are not supported
|
|
//~| NOTE consider moving this `else` clause to a separate `if` statement and use a `bool` variable to control if it should run
|
|
};
|
|
}
|