1 error: union expressions should have exactly one field
2 --> $DIR/union-fields-2.rs:17:13
4 LL | let u = U {}; //~ ERROR union expressions should have exactly one field
7 error: union expressions should have exactly one field
8 --> $DIR/union-fields-2.rs:19:13
10 LL | let u = U { a: 0, b: 1 }; //~ ERROR union expressions should have exactly one field
13 error[E0560]: union `U` has no field named `c`
14 --> $DIR/union-fields-2.rs:20:29
16 LL | let u = U { a: 0, b: 1, c: 2 }; //~ ERROR union expressions should have exactly one field
17 | ^ `U` does not have this field
19 = note: available fields are: `a`, `b`
21 error: union expressions should have exactly one field
22 --> $DIR/union-fields-2.rs:20:13
24 LL | let u = U { a: 0, b: 1, c: 2 }; //~ ERROR union expressions should have exactly one field
27 error: union expressions should have exactly one field
28 --> $DIR/union-fields-2.rs:22:13
30 LL | let u = U { ..u }; //~ ERROR union expressions should have exactly one field
33 error[E0436]: functional record update syntax requires a struct
34 --> $DIR/union-fields-2.rs:22:19
36 LL | let u = U { ..u }; //~ ERROR union expressions should have exactly one field
39 error: union patterns should have exactly one field
40 --> $DIR/union-fields-2.rs:25:9
42 LL | let U {} = u; //~ ERROR union patterns should have exactly one field
45 error: union patterns should have exactly one field
46 --> $DIR/union-fields-2.rs:27:9
48 LL | let U { a, b } = u; //~ ERROR union patterns should have exactly one field
51 error[E0026]: union `U` does not have a field named `c`
52 --> $DIR/union-fields-2.rs:28:19
54 LL | let U { a, b, c } = u; //~ ERROR union patterns should have exactly one field
55 | ^ union `U` does not have this field
57 error: union patterns should have exactly one field
58 --> $DIR/union-fields-2.rs:28:9
60 LL | let U { a, b, c } = u; //~ ERROR union patterns should have exactly one field
63 error: union patterns should have exactly one field
64 --> $DIR/union-fields-2.rs:30:9
66 LL | let U { .. } = u; //~ ERROR union patterns should have exactly one field
69 error: `..` cannot be used in union patterns
70 --> $DIR/union-fields-2.rs:30:9
72 LL | let U { .. } = u; //~ ERROR union patterns should have exactly one field
75 error: `..` cannot be used in union patterns
76 --> $DIR/union-fields-2.rs:32:9
78 LL | let U { a, .. } = u; //~ ERROR `..` cannot be used in union patterns
81 error: aborting due to 13 previous errors
83 Some errors occurred: E0026, E0436, E0560.
84 For more information about an error, try `rustc --explain E0026`.