summary refs log tree commit diff
path: root/src/test/run-pass/alt-implicit-copy-unique.rs
blob: bef4af11be4734eb22230237f7713fedc66e9be2 (plain)
1
2
3
4
5
6
fn main() {
    let x = ~{mut a: ~10, b: ~20};
    alt x {
      ~{a, b} { assert *a == 10; (*x).a = ~30; assert *a == 30; }
    }
}