Skip to content

Commit 0876f17

Browse files
committed
bool-comparison: make lint adhere to lint message convention
1 parent e57aafe commit 0876f17

File tree

2 files changed

+5
-5
lines changed

2 files changed

+5
-5
lines changed

clippy_lints/src/needless_bool.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -243,7 +243,7 @@ fn check_comparison<'a, 'tcx>(
243243
cx,
244244
BOOL_COMPARISON,
245245
e.span,
246-
"This comparison might be written more concisely",
246+
"this comparison might be written more concisely",
247247
"try simplifying it as shown",
248248
format!(
249249
"{} != {}",

tests/ui/bool_comparison.stderr

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -84,25 +84,25 @@ error: order comparisons between booleans can be simplified
8484
LL | if x > y {
8585
| ^^^^^ help: try simplifying it as shown: `x & !y`
8686

87-
error: This comparison might be written more concisely
87+
error: this comparison might be written more concisely
8888
--> $DIR/bool_comparison.rs:120:8
8989
|
9090
LL | if a == !b {};
9191
| ^^^^^^^ help: try simplifying it as shown: `a != b`
9292

93-
error: This comparison might be written more concisely
93+
error: this comparison might be written more concisely
9494
--> $DIR/bool_comparison.rs:121:8
9595
|
9696
LL | if !a == b {};
9797
| ^^^^^^^ help: try simplifying it as shown: `a != b`
9898

99-
error: This comparison might be written more concisely
99+
error: this comparison might be written more concisely
100100
--> $DIR/bool_comparison.rs:125:8
101101
|
102102
LL | if b == !a {};
103103
| ^^^^^^^ help: try simplifying it as shown: `b != a`
104104

105-
error: This comparison might be written more concisely
105+
error: this comparison might be written more concisely
106106
--> $DIR/bool_comparison.rs:126:8
107107
|
108108
LL | if !b == a {};

0 commit comments

Comments
 (0)