rust/src/test/compile-fail/or-init.rs
Tim Chevalier 28459ca0eb Handle lazy binops properly in typestate
The typestate analysis now reflects that the second operand of a
logical and or or may not be evaluated.
2011-06-28 13:07:52 -07:00

9 lines
160 B
Rust

// xfail-stage0
// error-pattern: Unsatisfied precondition constraint (for example, init(i
fn main() {
let int i;
log (false || {i = 5; true});
log i;
}