1 Attempted to access a non-existent field in a struct.
3 Erroneous code example:
6 struct StructWithFields {
10 let s = StructWithFields { x: 0 };
11 println!("{}", s.foo); // error: no field `foo` on type `StructWithFields`
14 To fix this error, check that you didn't misspell the field's name or that the
15 field actually exists. Example:
18 struct StructWithFields {
22 let s = StructWithFields { x: 0 };
23 println!("{}", s.x); // ok!