Skip to content

Commit 6764fde

Browse files
committed
Fix rust-lang#88256, remove duplicated diagnostic
1 parent c8262ad commit 6764fde

3 files changed

+3
-33
lines changed

tests/ui/match_same_arms.stderr

+1-19
Original file line numberDiff line numberDiff line change
@@ -106,24 +106,6 @@ LL | 1 => 2,
106106
| ^
107107
= help: ...or consider changing the match arm bodies
108108

109-
error: this `match` has identical arm bodies
110-
--> $DIR/match_same_arms.rs:33:14
111-
|
112-
LL | 3 => 2, //~ ERROR 3rd matched arms have same body
113-
| ^
114-
|
115-
note: same as this
116-
--> $DIR/match_same_arms.rs:32:14
117-
|
118-
LL | 2 => 2, //~ ERROR 2nd matched arms have same body
119-
| ^
120-
help: consider refactoring into `2 | 3`
121-
--> $DIR/match_same_arms.rs:32:9
122-
|
123-
LL | 2 => 2, //~ ERROR 2nd matched arms have same body
124-
| ^
125-
= help: ...or consider changing the match arm bodies
126-
127109
error: this `match` has identical arm bodies
128110
--> $DIR/match_same_arms.rs:50:55
129111
|
@@ -142,5 +124,5 @@ LL | CommandInfo::BuiltIn { name, .. } => name.to_string(),
142124
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
143125
= help: ...or consider changing the match arm bodies
144126

145-
error: aborting due to 8 previous errors
127+
error: aborting due to 7 previous errors
146128

tests/ui/modulo_one.stderr

+1-7
Original file line numberDiff line numberDiff line change
@@ -46,12 +46,6 @@ LL | const ONE: u32 = 1 * 1;
4646
|
4747
= note: `-D clippy::identity-op` implied by `-D warnings`
4848

49-
error: the operation is ineffective. Consider reducing it to `1`
50-
--> $DIR/modulo_one.rs:13:22
51-
|
52-
LL | const ONE: u32 = 1 * 1;
53-
| ^^^^^
54-
5549
error: any number modulo 1 will be 0
5650
--> $DIR/modulo_one.rs:17:5
5751
|
@@ -70,5 +64,5 @@ error: any number modulo -1 will panic/overflow or result in 0
7064
LL | INT_MIN % NEG_ONE; // also caught by rustc
7165
| ^^^^^^^^^^^^^^^^^
7266

73-
error: aborting due to 11 previous errors
67+
error: aborting due to 10 previous errors
7468

tests/ui/suspicious_operation_groupings.stderr

+1-7
Original file line numberDiff line numberDiff line change
@@ -6,12 +6,6 @@ LL | self.x == other.y && self.y == other.y && self.z == other.z
66
|
77
= note: `-D clippy::suspicious-operation-groupings` implied by `-D warnings`
88

9-
error: this sequence of operators looks suspiciously like a bug
10-
--> $DIR/suspicious_operation_groupings.rs:14:9
11-
|
12-
LL | self.x == other.y && self.y == other.y && self.z == other.z
13-
| ^^^^^^^^^^^^^^^^^ help: did you mean: `self.x == other.x`
14-
159
error: this sequence of operators looks suspiciously like a bug
1610
--> $DIR/suspicious_operation_groupings.rs:27:20
1711
|
@@ -162,5 +156,5 @@ error: this sequence of operators looks suspiciously like a bug
162156
LL | -(if -s1.a < -s2.a && -s1.a < -s2.b { s1.c } else { s2.a })
163157
| ^^^^^^^^^^^^^ help: did you mean: `-s1.b < -s2.b`
164158

165-
error: aborting due to 27 previous errors
159+
error: aborting due to 26 previous errors
166160

0 commit comments

Comments
 (0)