rust/src/test/compile-fail/liveness-uninit.rs

7 lines
125 B
Rust
Raw Normal View History

fn foo(x: int) { log(debug, x); }
fn main() {
let x: int;
foo(x); //! ERROR use of possibly uninitialized variable: `x`
}