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

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

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