summaryrefslogtreecommitdiffstats
path: root/tests/ui/structs-enums/struct-new-as-field-name.rs
blob: 641fc3c58670a478b29119a196c0fb17137c5eab (plain)
1
2
3
4
5
6
7
8
9
10
// run-pass

struct Foo {
    new: isize,
}

pub fn main() {
    let foo = Foo{ new: 3 };
    assert_eq!(foo.new, 3);
}