From 20431706a863f92cb37dc512fef6e48d192aaf2c Mon Sep 17 00:00:00 2001 From: Daniel Baumann Date: Wed, 17 Apr 2024 14:11:38 +0200 Subject: Merging upstream version 1.66.0+dfsg1. Signed-off-by: Daniel Baumann --- src/test/ui/pattern/usefulness/consts-opaque.stderr | 2 +- src/test/ui/pattern/usefulness/deny-irrefutable-let-patterns.stderr | 4 ++-- .../usefulness/integer-ranges/overlapping_range_endpoints.stderr | 2 +- 3 files changed, 4 insertions(+), 4 deletions(-) (limited to 'src/test/ui/pattern/usefulness') 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 + = 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 -- cgit v1.2.3