rust/src/test/run-pass/last-use-is-capture.rs
2012-12-05 17:36:51 -08:00

9 lines
157 B
Rust

// Make sure #1399 stays fixed
fn main() {
fn invoke(f: fn@()) { f(); }
let k = ~22;
let _u = {a: copy k};
invoke(|| log(error, copy k) )
}