diff options
| author | bors <bors@rust-lang.org> | 2020-06-13 15:50:56 +0000 |
|---|---|---|
| committer | bors <bors@rust-lang.org> | 2020-06-13 15:50:56 +0000 |
| commit | 06e47688bf15d0215edbe05b21603062f6d2eb5d (patch) | |
| tree | dea015bf136b986e4e1a93f5c0ee50318095113d /src/test/ui/pattern | |
| parent | 1fb612bd15bb3ef098fd24c20d0727de573b4410 (diff) | |
| parent | 8d97ccf954582b9040298fb0541aa7380a4db109 (diff) | |
Auto merge of #73316 - Dylan-DPC:rollup-zgouwou, r=Dylan-DPC
Rollup of 8 pull requests Successful merges: - #72932 (Clarify the behaviour of Pattern when used with methods like str::contains) - #73066 (Querify whether a type has structural equality (Take 2)) - #73194 (Prefer the associated constants for pattern matching error) - #73241 (Add/update comments about MinGW late_link_args) - #73267 (Use the built cargo for cargotest.) - #73290 (Fix links when pinging notification groups) - #73302 (Adjusted some doctests in libcore to use `should_panic`.) - #73308 (pretty/asm.rs should only be tested for x86_64 and not AArch64) Failed merges: r? @ghost
Diffstat (limited to 'src/test/ui/pattern')
7 files changed, 25 insertions, 25 deletions
diff --git a/src/test/ui/pattern/usefulness/exhaustive_integer_patterns.stderr b/src/test/ui/pattern/usefulness/exhaustive_integer_patterns.stderr index edc5ece558a..6427a30b8f2 100644 --- a/src/test/ui/pattern/usefulness/exhaustive_integer_patterns.stderr +++ b/src/test/ui/pattern/usefulness/exhaustive_integer_patterns.stderr @@ -10,11 +10,11 @@ note: the lint level is defined here LL | #![deny(unreachable_patterns)] | ^^^^^^^^^^^^^^^^^^^^ -error[E0004]: non-exhaustive patterns: `128u8..=std::u8::MAX` not covered +error[E0004]: non-exhaustive patterns: `128u8..=u8::MAX` not covered --> $DIR/exhaustive_integer_patterns.rs:28:11 | LL | match x { - | ^ pattern `128u8..=std::u8::MAX` not covered + | ^ pattern `128u8..=u8::MAX` not covered | = help: ensure that all possible cases are being handled, possibly by adding wildcards or more match arms = note: the matched value is of type `u8` @@ -34,20 +34,20 @@ error: unreachable pattern LL | -2..=20 => {} | ^^^^^^^ -error[E0004]: non-exhaustive patterns: `std::i8::MIN..=-8i8`, `-6i8`, `121i8..=124i8` and 1 more not covered +error[E0004]: non-exhaustive patterns: `i8::MIN..=-8i8`, `-6i8`, `121i8..=124i8` and 1 more not covered --> $DIR/exhaustive_integer_patterns.rs:41:11 | LL | match x { - | ^ patterns `std::i8::MIN..=-8i8`, `-6i8`, `121i8..=124i8` and 1 more not covered + | ^ patterns `i8::MIN..=-8i8`, `-6i8`, `121i8..=124i8` and 1 more not covered | = help: ensure that all possible cases are being handled, possibly by adding wildcards or more match arms = note: the matched value is of type `i8` -error[E0004]: non-exhaustive patterns: `std::i8::MIN` not covered +error[E0004]: non-exhaustive patterns: `i8::MIN` not covered --> $DIR/exhaustive_integer_patterns.rs:83:11 | LL | match 0i8 { - | ^^^ pattern `std::i8::MIN` not covered + | ^^^ pattern `i8::MIN` not covered | = help: ensure that all possible cases are being handled, possibly by adding wildcards or more match arms = note: the matched value is of type `i8` @@ -61,20 +61,20 @@ LL | match 0i16 { = help: ensure that all possible cases are being handled, possibly by adding wildcards or more match arms = note: the matched value is of type `i16` -error[E0004]: non-exhaustive patterns: `128u8..=std::u8::MAX` not covered +error[E0004]: non-exhaustive patterns: `128u8..=u8::MAX` not covered --> $DIR/exhaustive_integer_patterns.rs:109:11 | LL | match 0u8 { - | ^^^ pattern `128u8..=std::u8::MAX` not covered + | ^^^ pattern `128u8..=u8::MAX` not covered | = help: ensure that all possible cases are being handled, possibly by adding wildcards or more match arms = note: the matched value is of type `u8` -error[E0004]: non-exhaustive patterns: `(0u8, Some(_))` and `(2u8..=std::u8::MAX, Some(_))` not covered +error[E0004]: non-exhaustive patterns: `(0u8, Some(_))` and `(2u8..=u8::MAX, Some(_))` not covered --> $DIR/exhaustive_integer_patterns.rs:121:11 | LL | match (0u8, Some(())) { - | ^^^^^^^^^^^^^^^ patterns `(0u8, Some(_))` and `(2u8..=std::u8::MAX, Some(_))` not covered + | ^^^^^^^^^^^^^^^ patterns `(0u8, Some(_))` and `(2u8..=u8::MAX, Some(_))` not covered | = help: ensure that all possible cases are being handled, possibly by adding wildcards or more match arms = note: the matched value is of type `(u8, std::option::Option<()>)` @@ -102,20 +102,20 @@ note: the lint level is defined here LL | #![deny(overlapping_patterns)] | ^^^^^^^^^^^^^^^^^^^^ -error[E0004]: non-exhaustive patterns: `std::u128::MAX` not covered +error[E0004]: non-exhaustive patterns: `u128::MAX` not covered --> $DIR/exhaustive_integer_patterns.rs:146:11 | LL | match 0u128 { - | ^^^^^ pattern `std::u128::MAX` not covered + | ^^^^^ pattern `u128::MAX` not covered | = help: ensure that all possible cases are being handled, possibly by adding wildcards or more match arms = note: the matched value is of type `u128` -error[E0004]: non-exhaustive patterns: `5u128..=std::u128::MAX` not covered +error[E0004]: non-exhaustive patterns: `5u128..=u128::MAX` not covered --> $DIR/exhaustive_integer_patterns.rs:150:11 | LL | match 0u128 { - | ^^^^^ pattern `5u128..=std::u128::MAX` not covered + | ^^^^^ pattern `5u128..=u128::MAX` not covered | = help: ensure that all possible cases are being handled, possibly by adding wildcards or more match arms = note: the matched value is of type `u128` diff --git a/src/test/ui/pattern/usefulness/match-byte-array-patterns-2.stderr b/src/test/ui/pattern/usefulness/match-byte-array-patterns-2.stderr index 323449eebc5..0e12b89de1b 100644 --- a/src/test/ui/pattern/usefulness/match-byte-array-patterns-2.stderr +++ b/src/test/ui/pattern/usefulness/match-byte-array-patterns-2.stderr @@ -1,8 +1,8 @@ -error[E0004]: non-exhaustive patterns: `&[0u8..=64u8, _, _, _]` and `&[66u8..=std::u8::MAX, _, _, _]` not covered +error[E0004]: non-exhaustive patterns: `&[0u8..=64u8, _, _, _]` and `&[66u8..=u8::MAX, _, _, _]` not covered --> $DIR/match-byte-array-patterns-2.rs:4:11 | LL | match buf { - | ^^^ patterns `&[0u8..=64u8, _, _, _]` and `&[66u8..=std::u8::MAX, _, _, _]` not covered + | ^^^ patterns `&[0u8..=64u8, _, _, _]` and `&[66u8..=u8::MAX, _, _, _]` not covered | = help: ensure that all possible cases are being handled, possibly by adding wildcards or more match arms = note: the matched value is of type `&[u8; 4]` diff --git a/src/test/ui/pattern/usefulness/match-non-exhaustive.stderr b/src/test/ui/pattern/usefulness/match-non-exhaustive.stderr index 84cfe1da315..c6a9329f9e8 100644 --- a/src/test/ui/pattern/usefulness/match-non-exhaustive.stderr +++ b/src/test/ui/pattern/usefulness/match-non-exhaustive.stderr @@ -1,8 +1,8 @@ -error[E0004]: non-exhaustive patterns: `std::i32::MIN..=0i32` and `2i32..=std::i32::MAX` not covered +error[E0004]: non-exhaustive patterns: `i32::MIN..=0i32` and `2i32..=i32::MAX` not covered --> $DIR/match-non-exhaustive.rs:2:11 | LL | match 0 { 1 => () } - | ^ patterns `std::i32::MIN..=0i32` and `2i32..=std::i32::MAX` not covered + | ^ patterns `i32::MIN..=0i32` and `2i32..=i32::MAX` not covered | = help: ensure that all possible cases are being handled, possibly by adding wildcards or more match arms = note: the matched value is of type `i32` diff --git a/src/test/ui/pattern/usefulness/non-exhaustive-match.rs b/src/test/ui/pattern/usefulness/non-exhaustive-match.rs index 9947989dc12..9177345bc6f 100644 --- a/src/test/ui/pattern/usefulness/non-exhaustive-match.rs +++ b/src/test/ui/pattern/usefulness/non-exhaustive-match.rs @@ -11,8 +11,8 @@ fn main() { match Some(10) { //~ ERROR non-exhaustive patterns: `Some(_)` not covered None => {} } - match (2, 3, 4) { //~ ERROR non-exhaustive patterns: `(_, _, std::i32::MIN..=3i32)` - // and `(_, _, 5i32..=std::i32::MAX)` not covered + match (2, 3, 4) { //~ ERROR non-exhaustive patterns: `(_, _, i32::MIN..=3i32)` + // and `(_, _, 5i32..=i32::MAX)` not covered (_, _, 4) => {} } match (T::A, T::A) { //~ ERROR non-exhaustive patterns: `(A, A)` not covered diff --git a/src/test/ui/pattern/usefulness/non-exhaustive-match.stderr b/src/test/ui/pattern/usefulness/non-exhaustive-match.stderr index 436a293b6ce..3cdbd8a3433 100644 --- a/src/test/ui/pattern/usefulness/non-exhaustive-match.stderr +++ b/src/test/ui/pattern/usefulness/non-exhaustive-match.stderr @@ -36,11 +36,11 @@ LL | Some(#[stable(feature = "rust1", since = "1.0.0")] T), = help: ensure that all possible cases are being handled, possibly by adding wildcards or more match arms = note: the matched value is of type `std::option::Option<i32>` -error[E0004]: non-exhaustive patterns: `(_, _, std::i32::MIN..=3i32)` and `(_, _, 5i32..=std::i32::MAX)` not covered +error[E0004]: non-exhaustive patterns: `(_, _, i32::MIN..=3i32)` and `(_, _, 5i32..=i32::MAX)` not covered --> $DIR/non-exhaustive-match.rs:14:11 | LL | match (2, 3, 4) { - | ^^^^^^^^^ patterns `(_, _, std::i32::MIN..=3i32)` and `(_, _, 5i32..=std::i32::MAX)` not covered + | ^^^^^^^^^ patterns `(_, _, i32::MIN..=3i32)` and `(_, _, 5i32..=i32::MAX)` not covered | = help: ensure that all possible cases are being handled, possibly by adding wildcards or more match arms = note: the matched value is of type `(i32, i32, i32)` diff --git a/src/test/ui/pattern/usefulness/refutable-pattern-errors.rs b/src/test/ui/pattern/usefulness/refutable-pattern-errors.rs index d4afe17ca74..3ef2ead32cb 100644 --- a/src/test/ui/pattern/usefulness/refutable-pattern-errors.rs +++ b/src/test/ui/pattern/usefulness/refutable-pattern-errors.rs @@ -5,5 +5,5 @@ fn func((1, (Some(1), 2..=3)): (isize, (Option<isize>, isize))) { } fn main() { let (1, (Some(1), 2..=3)) = (1, (None, 2)); - //~^ ERROR refutable pattern in local binding: `(std::i32::MIN..=0i32, _)` and `(2i32..=std::i32::MAX, _)` not covered + //~^ ERROR refutable pattern in local binding: `(i32::MIN..=0i32, _)` and `(2i32..=i32::MAX, _)` not covered } diff --git a/src/test/ui/pattern/usefulness/refutable-pattern-errors.stderr b/src/test/ui/pattern/usefulness/refutable-pattern-errors.stderr index f5895c01599..ac729ae9f7c 100644 --- a/src/test/ui/pattern/usefulness/refutable-pattern-errors.stderr +++ b/src/test/ui/pattern/usefulness/refutable-pattern-errors.stderr @@ -6,11 +6,11 @@ LL | fn func((1, (Some(1), 2..=3)): (isize, (Option<isize>, isize))) { } | = note: the matched value is of type `(isize, (std::option::Option<isize>, isize))` -error[E0005]: refutable pattern in local binding: `(std::i32::MIN..=0i32, _)` and `(2i32..=std::i32::MAX, _)` not covered +error[E0005]: refutable pattern in local binding: `(i32::MIN..=0i32, _)` and `(2i32..=i32::MAX, _)` not covered --> $DIR/refutable-pattern-errors.rs:7:9 | LL | let (1, (Some(1), 2..=3)) = (1, (None, 2)); - | ^^^^^^^^^^^^^^^^^^^^^ patterns `(std::i32::MIN..=0i32, _)` and `(2i32..=std::i32::MAX, _)` not covered + | ^^^^^^^^^^^^^^^^^^^^^ patterns `(i32::MIN..=0i32, _)` and `(2i32..=i32::MAX, _)` not covered | = note: `let` bindings require an "irrefutable pattern", like a `struct` or an `enum` with only one variant = note: for more information, visit https://doc.rust-lang.org/book/ch18-02-refutability.html |
