mirror of
https://github.com/rust-lang/rust.git
synced 2024-11-01 06:51:58 +00:00
21 lines
297 B
Rust
21 lines
297 B
Rust
fn and_chain() {
|
|
let z;
|
|
if true && { z = 3; true} && z == 3 {}
|
|
//~^ ERROR E0381
|
|
}
|
|
|
|
fn and_chain_2() {
|
|
let z;
|
|
true && { z = 3; true} && z == 3;
|
|
//~^ ERROR E0381
|
|
}
|
|
|
|
fn or_chain() {
|
|
let z;
|
|
if false || { z = 3; false} || z == 3 {}
|
|
//~^ ERROR E0381
|
|
}
|
|
|
|
fn main() {
|
|
}
|