]> git.lizzy.rs Git - rust.git/commitdiff
Fix #88256, remove duplicated diagnostic
authoryukang <moorekang@gmail.com>
Sat, 4 Sep 2021 11:26:25 +0000 (19:26 +0800)
committeryukang <moorekang@gmail.com>
Sat, 4 Sep 2021 11:26:25 +0000 (19:26 +0800)
tests/ui/match_same_arms.stderr
tests/ui/modulo_one.stderr
tests/ui/suspicious_operation_groupings.stderr

index e48451acfe8f5f4c67f76c65298e40b9a463e9f5..7752a8a6ff2b4094a3089d3295d77b4d2a44f597 100644 (file)
@@ -106,24 +106,6 @@ LL |         1 => 2,
    |         ^
    = help: ...or consider changing the match arm bodies
 
-error: this `match` has identical arm bodies
-  --> $DIR/match_same_arms.rs:33:14
-   |
-LL |         3 => 2, //~ ERROR 3rd matched arms have same body
-   |              ^
-   |
-note: same as this
-  --> $DIR/match_same_arms.rs:32:14
-   |
-LL |         2 => 2, //~ ERROR 2nd matched arms have same body
-   |              ^
-help: consider refactoring into `2 | 3`
-  --> $DIR/match_same_arms.rs:32:9
-   |
-LL |         2 => 2, //~ ERROR 2nd matched arms have same body
-   |         ^
-   = help: ...or consider changing the match arm bodies
-
 error: this `match` has identical arm bodies
   --> $DIR/match_same_arms.rs:50:55
    |
@@ -142,5 +124,5 @@ LL |                 CommandInfo::BuiltIn { name, .. } => name.to_string(),
    |                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    = help: ...or consider changing the match arm bodies
 
-error: aborting due to 8 previous errors
+error: aborting due to 7 previous errors
 
index 2b2c699733852dd464507708dc41ad79a15b92eb..34f762bbb923648996cb56af20e84dba18b4fb47 100644 (file)
@@ -46,12 +46,6 @@ LL |     const ONE: u32 = 1 * 1;
    |
    = note: `-D clippy::identity-op` implied by `-D warnings`
 
-error: the operation is ineffective. Consider reducing it to `1`
-  --> $DIR/modulo_one.rs:13:22
-   |
-LL |     const ONE: u32 = 1 * 1;
-   |                      ^^^^^
-
 error: any number modulo 1 will be 0
   --> $DIR/modulo_one.rs:17:5
    |
@@ -70,5 +64,5 @@ error: any number modulo -1 will panic/overflow or result in 0
 LL |     INT_MIN % NEG_ONE; // also caught by rustc
    |     ^^^^^^^^^^^^^^^^^
 
-error: aborting due to 11 previous errors
+error: aborting due to 10 previous errors
 
index 96065699d321a057f9a8e28bf07ad3e4551ee282..dd6f2f6641d678b14b1d401fac951d98ce43f913 100644 (file)
@@ -6,12 +6,6 @@ LL |         self.x == other.y && self.y == other.y && self.z == other.z
    |
    = note: `-D clippy::suspicious-operation-groupings` implied by `-D warnings`
 
-error: this sequence of operators looks suspiciously like a bug
-  --> $DIR/suspicious_operation_groupings.rs:14:9
-   |
-LL |         self.x == other.y && self.y == other.y && self.z == other.z
-   |         ^^^^^^^^^^^^^^^^^ help: did you mean: `self.x == other.x`
-
 error: this sequence of operators looks suspiciously like a bug
   --> $DIR/suspicious_operation_groupings.rs:27:20
    |
@@ -162,5 +156,5 @@ error: this sequence of operators looks suspiciously like a bug
 LL |     -(if -s1.a < -s2.a && -s1.a < -s2.b { s1.c } else { s2.a })
    |                           ^^^^^^^^^^^^^ help: did you mean: `-s1.b < -s2.b`
 
-error: aborting due to 27 previous errors
+error: aborting due to 26 previous errors