fork/rust

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

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

master
1.1 KiB37 linesraw
1error[E0004]: non-exhaustive patterns: type `&!` is non-empty
2  --> $DIR/always-inhabited-union-ref.rs:23:11
3   |
4LL |     match uninhab_ref() {
5   |           ^^^^^^^^^^^^^
6   |
7   = note: the matched value is of type `&!`
8   = note: references are always considered inhabited
9help: ensure that all possible cases are being handled by adding a match arm with a wildcard pattern as shown
10   |
11LL ~     match uninhab_ref() {
12LL +         _ => todo!(),
13LL +     }
14   |
15
16error[E0004]: non-exhaustive patterns: type `Foo` is non-empty
17  --> $DIR/always-inhabited-union-ref.rs:27:11
18   |
19LL |     match uninhab_union() {
20   |           ^^^^^^^^^^^^^^^
21   |
22note: `Foo` defined here
23  --> $DIR/always-inhabited-union-ref.rs:10:11
24   |
25LL | pub union Foo {
26   |           ^^^
27   = note: the matched value is of type `Foo`
28help: ensure that all possible cases are being handled by adding a match arm with a wildcard pattern as shown
29   |
30LL ~     match uninhab_union() {
31LL +         _ => todo!(),
32LL +     }
33   |
34
35error: aborting due to 2 previous errors
36
37For more information about this error, try `rustc --explain E0004`.