]> git.proxmox.com Git - rustc.git/blob - src/test/ui/pattern/usefulness/non-exhaustive-match.stderr
New upstream version 1.47.0~beta.2+dfsg1
[rustc.git] / src / test / ui / pattern / usefulness / non-exhaustive-match.stderr
1 error[E0004]: non-exhaustive patterns: `A` not covered
2 --> $DIR/non-exhaustive-match.rs:7:11
3 |
4 LL | enum T { A, B }
5 | ---------------
6 | | |
7 | | not covered
8 | `T` defined here
9 ...
10 LL | match x { T::B => { } }
11 | ^ pattern `A` not covered
12 |
13 = help: ensure that all possible cases are being handled, possibly by adding wildcards or more match arms
14 = note: the matched value is of type `T`
15
16 error[E0004]: non-exhaustive patterns: `false` not covered
17 --> $DIR/non-exhaustive-match.rs:8:11
18 |
19 LL | match true {
20 | ^^^^ pattern `false` not covered
21 |
22 = help: ensure that all possible cases are being handled, possibly by adding wildcards or more match arms
23 = note: the matched value is of type `bool`
24
25 error[E0004]: non-exhaustive patterns: `Some(_)` not covered
26 --> $DIR/non-exhaustive-match.rs:11:11
27 |
28 LL | match Some(10) {
29 | ^^^^^^^^ pattern `Some(_)` not covered
30 |
31 ::: $SRC_DIR/core/src/option.rs:LL:COL
32 |
33 LL | Some(#[stable(feature = "rust1", since = "1.0.0")] T),
34 | ---- not covered
35 |
36 = help: ensure that all possible cases are being handled, possibly by adding wildcards or more match arms
37 = note: the matched value is of type `std::option::Option<i32>`
38
39 error[E0004]: non-exhaustive patterns: `(_, _, i32::MIN..=3_i32)` and `(_, _, 5_i32..=i32::MAX)` not covered
40 --> $DIR/non-exhaustive-match.rs:14:11
41 |
42 LL | match (2, 3, 4) {
43 | ^^^^^^^^^ patterns `(_, _, i32::MIN..=3_i32)` and `(_, _, 5_i32..=i32::MAX)` not covered
44 |
45 = help: ensure that all possible cases are being handled, possibly by adding wildcards or more match arms
46 = note: the matched value is of type `(i32, i32, i32)`
47
48 error[E0004]: non-exhaustive patterns: `(A, A)` not covered
49 --> $DIR/non-exhaustive-match.rs:18:11
50 |
51 LL | match (T::A, T::A) {
52 | ^^^^^^^^^^^^ pattern `(A, A)` not covered
53 |
54 = help: ensure that all possible cases are being handled, possibly by adding wildcards or more match arms
55 = note: the matched value is of type `(T, T)`
56
57 error[E0004]: non-exhaustive patterns: `B` not covered
58 --> $DIR/non-exhaustive-match.rs:22:11
59 |
60 LL | enum T { A, B }
61 | ---------------
62 | | |
63 | | not covered
64 | `T` defined here
65 ...
66 LL | match T::A {
67 | ^^^^ pattern `B` not covered
68 |
69 = help: ensure that all possible cases are being handled, possibly by adding wildcards or more match arms
70 = note: the matched value is of type `T`
71
72 error[E0004]: non-exhaustive patterns: `[]` not covered
73 --> $DIR/non-exhaustive-match.rs:33:11
74 |
75 LL | match *vec {
76 | ^^^^ pattern `[]` not covered
77 |
78 = help: ensure that all possible cases are being handled, possibly by adding wildcards or more match arms
79 = note: the matched value is of type `[std::option::Option<isize>]`
80
81 error[E0004]: non-exhaustive patterns: `[_, _, _, _, ..]` not covered
82 --> $DIR/non-exhaustive-match.rs:46:11
83 |
84 LL | match *vec {
85 | ^^^^ pattern `[_, _, _, _, ..]` not covered
86 |
87 = help: ensure that all possible cases are being handled, possibly by adding wildcards or more match arms
88 = note: the matched value is of type `[f32]`
89
90 error: aborting due to 8 previous errors
91
92 For more information about this error, try `rustc --explain E0004`.