rust/tests/ui/pattern/usefulness/issue-30240.stderr

30 lines
942 B
Plaintext
Raw Normal View History

error[E0004]: non-exhaustive patterns: `&_` not covered
2018-12-25 09:56:47 -06:00
--> $DIR/issue-30240.rs:2:11
2018-07-15 16:11:54 -05:00
|
2019-03-09 06:03:44 -06:00
LL | match "world" {
| ^^^^^^^ pattern `&_` not covered
|
= note: the matched value is of type `&str`
help: ensure that all possible cases are being handled by adding a match arm with a wildcard pattern or an explicit pattern as shown
|
2023-02-27 11:43:39 -06:00
LL ~ "hello" => {},
LL + &_ => todo!()
|
2018-07-15 16:11:54 -05:00
error[E0004]: non-exhaustive patterns: `&_` not covered
2018-12-25 09:56:47 -06:00
--> $DIR/issue-30240.rs:6:11
2018-07-15 16:11:54 -05:00
|
2019-03-09 06:03:44 -06:00
LL | match "world" {
| ^^^^^^^ pattern `&_` not covered
|
= note: the matched value is of type `&str`
help: ensure that all possible cases are being handled by adding a match arm with a wildcard pattern or an explicit pattern as shown
|
2023-02-27 11:43:39 -06:00
LL ~ "hello" => {},
LL + &_ => todo!()
|
2018-07-15 16:11:54 -05:00
error: aborting due to 2 previous errors
For more information about this error, try `rustc --explain E0004`.