1 error[E0423]: expected function, found struct `TupleStruct`
2 --> $DIR/structs.rs:20:14
4 LL | let ts = TupleStruct(640, 480);
5 | ^^^^^^^^^^^ constructor is not visible here due to private fields
7 error[E0423]: expected value, found struct `UnitStruct`
8 --> $DIR/structs.rs:29:14
10 LL | let us = UnitStruct;
11 | ^^^^^^^^^^ constructor is not visible here due to private fields
13 error[E0603]: tuple struct `TupleStruct` is private
14 --> $DIR/structs.rs:23:32
16 LL | let ts_explicit = structs::TupleStruct(640, 480);
19 error[E0603]: unit struct `UnitStruct` is private
20 --> $DIR/structs.rs:32:32
22 LL | let us_explicit = structs::UnitStruct;
25 error[E0639]: cannot create non-exhaustive struct using struct expression
26 --> $DIR/structs.rs:7:14
28 LL | let fr = FunctionalRecord {
30 LL | | //~^ ERROR cannot create non-exhaustive struct
31 LL | | first_field: 1920,
32 LL | | second_field: 1080,
33 LL | | ..FunctionalRecord::default()
37 error[E0639]: cannot create non-exhaustive struct using struct expression
38 --> $DIR/structs.rs:14:14
40 LL | let ns = NormalStruct { first_field: 640, second_field: 480 };
41 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
43 error[E0638]: `..` required with struct marked as non-exhaustive
44 --> $DIR/structs.rs:17:9
46 LL | let NormalStruct { first_field, second_field } = ns;
47 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
49 error[E0638]: `..` required with struct marked as non-exhaustive
50 --> $DIR/structs.rs:26:9
52 LL | let TupleStruct { 0: first_field, 1: second_field } = ts;
53 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
55 error[E0638]: `..` required with struct marked as non-exhaustive
56 --> $DIR/structs.rs:35:9
58 LL | let UnitStruct { } = us;
61 error: aborting due to 9 previous errors
63 Some errors occurred: E0423, E0603, E0638, E0639.
64 For more information about an error, try `rustc --explain E0423`.