summary refs log tree commit diff
path: root/src/test/run-pass/cycle-collection2.rs
blob: 33609d17c09d85902cc12dd7873173825c04fb03 (plain)
1
2
3
4
5
6
7
8
9
10
type foo = { mutable z : fn@() };

fn nop() { }
fn nop_foo(_x : @foo) { }

fn main() {
    let w = @{ mutable z: bind nop() };
    let x = bind nop_foo(w);
    w.z = x;
}