rust/src/test/run-pass/issue-979.rs
2012-03-26 18:35:18 -07:00

12 lines
136 B
Rust

resource r(b: @mut int) {
*b += 1;
}
fn main() {
let b = @mut 0;
{
let p = some(r(b));
}
assert *b == 1;
}