summaryrefslogtreecommitdiffstats
path: root/src/test/ui/pattern/usefulness
diff options
context:
space:
mode:
Diffstat (limited to 'src/test/ui/pattern/usefulness')
-rw-r--r--src/test/ui/pattern/usefulness/consts-opaque.stderr2
-rw-r--r--src/test/ui/pattern/usefulness/deny-irrefutable-let-patterns.stderr4
-rw-r--r--src/test/ui/pattern/usefulness/integer-ranges/overlapping_range_endpoints.stderr2
3 files changed, 4 insertions, 4 deletions
diff --git a/src/test/ui/pattern/usefulness/consts-opaque.stderr b/src/test/ui/pattern/usefulness/consts-opaque.stderr
index 05c009a6f..35396751a 100644
--- a/src/test/ui/pattern/usefulness/consts-opaque.stderr
+++ b/src/test/ui/pattern/usefulness/consts-opaque.stderr
@@ -40,9 +40,9 @@ warning: to use a constant of type `Foo` in a pattern, `Foo` must be annotated w
LL | FOO_REF_REF => {}
| ^^^^^^^^^^^
|
- = note: `#[warn(indirect_structural_match)]` on by default
= warning: this was previously accepted by the compiler but is being phased out; it will become a hard error in a future release!
= note: for more information, see issue #62411 <https://github.com/rust-lang/rust/issues/62411>
+ = note: `#[warn(indirect_structural_match)]` on by default
error: to use a constant of type `Bar` in a pattern, `Bar` must be annotated with `#[derive(PartialEq, Eq)]`
--> $DIR/consts-opaque.rs:53:9
diff --git a/src/test/ui/pattern/usefulness/deny-irrefutable-let-patterns.stderr b/src/test/ui/pattern/usefulness/deny-irrefutable-let-patterns.stderr
index b97683526..cdb6b5c7a 100644
--- a/src/test/ui/pattern/usefulness/deny-irrefutable-let-patterns.stderr
+++ b/src/test/ui/pattern/usefulness/deny-irrefutable-let-patterns.stderr
@@ -4,13 +4,13 @@ error: irrefutable `if let` pattern
LL | if let _ = 5 {}
| ^^^^^^^^^
|
+ = note: this pattern will always match, so the `if let` is useless
+ = help: consider replacing the `if let` with a `let`
note: the lint level is defined here
--> $DIR/deny-irrefutable-let-patterns.rs:3:9
|
LL | #![deny(irrefutable_let_patterns)]
| ^^^^^^^^^^^^^^^^^^^^^^^^
- = note: this pattern will always match, so the `if let` is useless
- = help: consider replacing the `if let` with a `let`
error: irrefutable `while let` pattern
--> $DIR/deny-irrefutable-let-patterns.rs:8:11
diff --git a/src/test/ui/pattern/usefulness/integer-ranges/overlapping_range_endpoints.stderr b/src/test/ui/pattern/usefulness/integer-ranges/overlapping_range_endpoints.stderr
index 24c0419e1..ea0e8f6e4 100644
--- a/src/test/ui/pattern/usefulness/integer-ranges/overlapping_range_endpoints.stderr
+++ b/src/test/ui/pattern/usefulness/integer-ranges/overlapping_range_endpoints.stderr
@@ -6,12 +6,12 @@ LL | m!(0u8, 20..=30, 30..=40);
| |
| this range overlaps on `30_u8`...
|
+ = note: you likely meant to write mutually exclusive ranges
note: the lint level is defined here
--> $DIR/overlapping_range_endpoints.rs:2:9
|
LL | #![deny(overlapping_range_endpoints)]
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^
- = note: you likely meant to write mutually exclusive ranges
error: multiple patterns overlap on their endpoints
--> $DIR/overlapping_range_endpoints.rs:16:22