fork/rust

git clone https://git.julia.blue/fork/rust

borsAuto merge of #103046 - JanBeh:PR_clarify_cmp_terminology, r=workingjubilee3bcad65fbf6

master
2.6 KiB95 linesraw
1error[E0532]: expected tuple struct or tuple variant, found struct `Empty1`
2  --> $DIR/empty-struct-braces-pat-2.rs:15:9
3   |
4LL | struct Empty1 {}
5   | ---------------- `Empty1` defined here
6...
7LL |         Empty1() => ()
8   |         ^^^^^^^^
9   |
10  ::: $DIR/auxiliary/empty-struct.rs:3:1
11   |
12LL | pub struct XEmpty6();
13   | ------------------ similarly named tuple struct `XEmpty6` defined here
14   |
15help: use struct pattern syntax instead
16   |
17LL |         Empty1 {} => ()
18   |         ~~~~~~~~~
19help: a tuple struct with a similar name exists
20   |
21LL |         XEmpty6() => ()
22   |         ~~~~~~~
23
24error[E0532]: expected tuple struct or tuple variant, found struct `XEmpty1`
25  --> $DIR/empty-struct-braces-pat-2.rs:18:9
26   |
27LL |         XEmpty1() => ()
28   |         ^^^^^^^^^
29   |
30  ::: $DIR/auxiliary/empty-struct.rs:1:1
31   |
32LL | pub struct XEmpty1 {}
33   | ------------------ `XEmpty1` defined here
34LL | pub struct XEmpty2;
35LL | pub struct XEmpty6();
36   | ------------------ similarly named tuple struct `XEmpty6` defined here
37   |
38help: use struct pattern syntax instead
39   |
40LL |         XEmpty1 {} => ()
41   |         ~~~~~~~~~~
42help: a tuple struct with a similar name exists
43   |
44LL |         XEmpty6() => ()
45   |         ~~~~~~~
46
47error[E0532]: expected tuple struct or tuple variant, found struct `Empty1`
48  --> $DIR/empty-struct-braces-pat-2.rs:21:9
49   |
50LL | struct Empty1 {}
51   | ---------------- `Empty1` defined here
52...
53LL |         Empty1(..) => ()
54   |         ^^^^^^^^^^
55   |
56  ::: $DIR/auxiliary/empty-struct.rs:3:1
57   |
58LL | pub struct XEmpty6();
59   | ------------------ similarly named tuple struct `XEmpty6` defined here
60   |
61help: use struct pattern syntax instead
62   |
63LL |         Empty1 {} => ()
64   |         ~~~~~~~~~
65help: a tuple struct with a similar name exists
66   |
67LL |         XEmpty6(..) => ()
68   |         ~~~~~~~
69
70error[E0532]: expected tuple struct or tuple variant, found struct `XEmpty1`
71  --> $DIR/empty-struct-braces-pat-2.rs:24:9
72   |
73LL |         XEmpty1(..) => ()
74   |         ^^^^^^^^^^^
75   |
76  ::: $DIR/auxiliary/empty-struct.rs:1:1
77   |
78LL | pub struct XEmpty1 {}
79   | ------------------ `XEmpty1` defined here
80LL | pub struct XEmpty2;
81LL | pub struct XEmpty6();
82   | ------------------ similarly named tuple struct `XEmpty6` defined here
83   |
84help: use struct pattern syntax instead
85   |
86LL |         XEmpty1 {} => ()
87   |         ~~~~~~~~~~
88help: a tuple struct with a similar name exists
89   |
90LL |         XEmpty6(..) => ()
91   |         ~~~~~~~
92
93error: aborting due to 4 previous errors
94
95For more information about this error, try `rustc --explain E0532`.