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