summary refs log tree commit diff
path: root/src/test/run-pass/struct-field-assignability.rs
blob: 1e13c7b86bf8c1c88a4436841a4103a05fc0b4a3 (plain)
1
2
3
4
5
6
7
8
9
struct Foo<'self> {
    x: &'self int
}

pub fn main() {
    let f = Foo { x: @3 };
    assert!(*f.x == 3);
}