diff options
| author | Oliver Scherer <github35764891676564198441@oli-obk.de> | 2020-09-23 18:04:44 +0200 |
|---|---|---|
| committer | Oliver Scherer <github35764891676564198441@oli-obk.de> | 2020-09-23 18:04:44 +0200 |
| commit | 017423179a9ea3267d0fab7bd20fd73b0cd8a528 (patch) | |
| tree | 179f501af4b04220416e22fee3ea7cfd7de35688 /src | |
| parent | 6a33de017007233346c26a6f7b20c3e35e6b9e90 (diff) | |
| download | rust-017423179a9ea3267d0fab7bd20fd73b0cd8a528.tar.gz rust-017423179a9ea3267d0fab7bd20fd73b0cd8a528.zip | |
Make sure we report a future incompat error in all cases
Diffstat (limited to 'src')
4 files changed, 23 insertions, 15 deletions
diff --git a/src/test/ui/consts/match_ice.stderr b/src/test/ui/consts/match_ice.stderr index 915111b3ce4..c46f2c2e972 100644 --- a/src/test/ui/consts/match_ice.stderr +++ b/src/test/ui/consts/match_ice.stderr @@ -1,12 +1,12 @@ -warning: to use a constant of type `&S` in a pattern, the constant's initializer must be trivial or all types in the constant must be annotated with `#[derive(PartialEq, Eq)]` +warning: to use a constant of type `S` in a pattern, `S` must be annotated with `#[derive(PartialEq, Eq)]` --> $DIR/match_ice.rs:11:9 | LL | C => {} | ^ | - = note: `#[warn(nontrivial_structural_match)]` on by default + = 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 #73448 <https://github.com/rust-lang/rust/issues/73448> + = note: for more information, see issue #62411 <https://github.com/rust-lang/rust/issues/62411> error: to use a constant of type `S` in a pattern, `S` must be annotated with `#[derive(PartialEq, Eq)]` --> $DIR/match_ice.rs:11:9 diff --git a/src/test/ui/rfc1445/cant-hide-behind-doubly-indirect-embedded.stderr b/src/test/ui/rfc1445/cant-hide-behind-doubly-indirect-embedded.stderr index eb13eed6ec1..659a9812672 100644 --- a/src/test/ui/rfc1445/cant-hide-behind-doubly-indirect-embedded.stderr +++ b/src/test/ui/rfc1445/cant-hide-behind-doubly-indirect-embedded.stderr @@ -1,12 +1,16 @@ -warning: to use a constant of type `&&WrapInline` in a pattern, the constant's initializer must be trivial or all types in the constant must be annotated with `#[derive(PartialEq, Eq)]` +warning: to use a constant of type `NoDerive` in a pattern, `NoDerive` must be annotated with `#[derive(PartialEq, Eq)]` --> $DIR/cant-hide-behind-doubly-indirect-embedded.rs:24:9 | LL | WRAP_DOUBLY_INDIRECT_INLINE => { panic!("WRAP_DOUBLY_INDIRECT_INLINE matched itself"); } | ^^^^^^^^^^^^^^^^^^^^^^^^^^^ | - = note: `#[warn(nontrivial_structural_match)]` on by default +note: the lint level is defined here + --> $DIR/cant-hide-behind-doubly-indirect-embedded.rs:7:9 + | +LL | #![warn(indirect_structural_match)] + | ^^^^^^^^^^^^^^^^^^^^^^^^^ = 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 #73448 <https://github.com/rust-lang/rust/issues/73448> + = note: for more information, see issue #62411 <https://github.com/rust-lang/rust/issues/62411> warning: 1 warning emitted diff --git a/src/test/ui/rfc1445/cant-hide-behind-doubly-indirect-param.stderr b/src/test/ui/rfc1445/cant-hide-behind-doubly-indirect-param.stderr index ddee99e76bb..c8c36510542 100644 --- a/src/test/ui/rfc1445/cant-hide-behind-doubly-indirect-param.stderr +++ b/src/test/ui/rfc1445/cant-hide-behind-doubly-indirect-param.stderr @@ -1,12 +1,16 @@ -warning: to use a constant of type `&&WrapParam<NoDerive>` in a pattern, the constant's initializer must be trivial or all types in the constant must be annotated with `#[derive(PartialEq, Eq)]` +warning: to use a constant of type `NoDerive` in a pattern, `NoDerive` must be annotated with `#[derive(PartialEq, Eq)]` --> $DIR/cant-hide-behind-doubly-indirect-param.rs:24:9 | LL | WRAP_DOUBLY_INDIRECT_PARAM => { panic!("WRAP_DOUBLY_INDIRECT_PARAM matched itself"); } | ^^^^^^^^^^^^^^^^^^^^^^^^^^ | - = note: `#[warn(nontrivial_structural_match)]` on by default +note: the lint level is defined here + --> $DIR/cant-hide-behind-doubly-indirect-param.rs:7:9 + | +LL | #![warn(indirect_structural_match)] + | ^^^^^^^^^^^^^^^^^^^^^^^^^ = 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 #73448 <https://github.com/rust-lang/rust/issues/73448> + = note: for more information, see issue #62411 <https://github.com/rust-lang/rust/issues/62411> warning: 1 warning emitted diff --git a/src/test/ui/rfc1445/issue-62307-match-ref-ref-forbidden-without-eq.stderr b/src/test/ui/rfc1445/issue-62307-match-ref-ref-forbidden-without-eq.stderr index 7f4b4923332..a50093a5b11 100644 --- a/src/test/ui/rfc1445/issue-62307-match-ref-ref-forbidden-without-eq.stderr +++ b/src/test/ui/rfc1445/issue-62307-match-ref-ref-forbidden-without-eq.stderr @@ -1,25 +1,25 @@ -warning: to use a constant of type `&&B` in a pattern, the constant's initializer must be trivial or all types in the constant must be annotated with `#[derive(PartialEq, Eq)]` +warning: to use a constant of type `B` in a pattern, `B` must be annotated with `#[derive(PartialEq, Eq)]` --> $DIR/issue-62307-match-ref-ref-forbidden-without-eq.rs:31:9 | LL | RR_B1 => { println!("CLAIM RR0: {:?} matches {:?}", RR_B1, RR_B0); } | ^^^^^ | note: the lint level is defined here - --> $DIR/issue-62307-match-ref-ref-forbidden-without-eq.rs:13:36 + --> $DIR/issue-62307-match-ref-ref-forbidden-without-eq.rs:13:9 | LL | #![warn(indirect_structural_match, nontrivial_structural_match)] - | ^^^^^^^^^^^^^^^^^^^^^^^^^^^ + | ^^^^^^^^^^^^^^^^^^^^^^^^^ = 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 #73448 <https://github.com/rust-lang/rust/issues/73448> + = note: for more information, see issue #62411 <https://github.com/rust-lang/rust/issues/62411> -warning: to use a constant of type `&&B` in a pattern, the constant's initializer must be trivial or all types in the constant must be annotated with `#[derive(PartialEq, Eq)]` +warning: to use a constant of type `B` in a pattern, `B` must be annotated with `#[derive(PartialEq, Eq)]` --> $DIR/issue-62307-match-ref-ref-forbidden-without-eq.rs:38:9 | LL | RR_B1 => { println!("CLAIM RR1: {:?} matches {:?}", RR_B1, RR_B1); } | ^^^^^ | = 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 #73448 <https://github.com/rust-lang/rust/issues/73448> + = note: for more information, see issue #62411 <https://github.com/rust-lang/rust/issues/62411> warning: 2 warnings emitted |
