1 // revisions: mirunsafeck thirunsafeck
2 // [thirunsafeck]compile-flags: -Z thir-unsafeck
13 let u = U { principle: 0 };
14 //~^ ERROR union `U` has no field named `principle`
15 //~| HELP a field with a similar name exists
16 //~| SUGGESTION principal
17 let w = u.principial; //~ ERROR no field `principial` on type `U`
18 //~| HELP a field with a similar name exists
19 //~| SUGGESTION principal
21 let y = u.calculate; //~ ERROR attempted to take value of method `calculate` on type `U`
22 //~| HELP use parentheses to call the method