fork/rust
git clone https://git.julia.blue/fork/rust
3bcad65fbf6
master
1// run-rustfix 2 3struct Foo { 4 first: Bar, 5 _second: u32, 6 _third: Vec<String>, 7} 8 9struct Bar { 10 bar: C, 11} 12 13struct C { 14 c: D, 15} 16 17struct D { 18 test: E, 19} 20 21struct E { 22 _e: F, 23} 24 25struct F { 26 _f: u32, 27} 28 29fn main() { 30 let f = F { _f: 6 }; 31 let e = E { _e: f }; 32 let d = D { test: e }; 33 let c = C { c: d }; 34 let bar = Bar { bar: c }; 35 let fooer = Foo { first: bar, _second: 4, _third: Vec::new() }; 36 37 let _test = &fooer.first.bar.c; 38 //~^ ERROR no field 39 40 let _test2 = fooer.first.bar.c.test; 41 //~^ ERROR no field 42}