fork/rust

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

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

master
892 B32 linesraw
1error[E0532]: expected unit struct, unit variant or constant, found tuple variant `Foo::Bar`
2  --> $DIR/issue-32004.rs:10:9
3   |
4LL |     Bar(i32),
5   |     -------- `Foo::Bar` defined here
6LL |     Baz
7   |     --- similarly named unit variant `Baz` defined here
8...
9LL |         Foo::Bar => {}
10   |         ^^^^^^^^
11   |
12help: use the tuple variant pattern syntax instead
13   |
14LL |         Foo::Bar(_) => {}
15   |         ~~~~~~~~~~~
16help: a unit variant with a similar name exists
17   |
18LL |         Foo::Baz => {}
19   |              ~~~
20
21error[E0532]: expected tuple struct or tuple variant, found unit struct `S`
22  --> $DIR/issue-32004.rs:16:9
23   |
24LL | struct S;
25   | --------- `S` defined here
26...
27LL |         S(()) => {}
28   |         ^^^^^ help: use this syntax instead: `S`
29
30error: aborting due to 2 previous errors
31
32For more information about this error, try `rustc --explain E0532`.