-
-
Notifications
You must be signed in to change notification settings - Fork 1.2k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[compare-to-zero] More actionnable and understandable message
Originally done in order to normalize the use-implicit-booleaness check. This make the message more understandable and permit to make #6870 more reviewable.
- Loading branch information
1 parent
f5f9e26
commit 6d896f3
Showing
2 changed files
with
19 additions
and
6 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,4 @@ | ||
compare-to-zero:6:3:6:9::Avoid comparisons to zero:HIGH | ||
compare-to-zero:9:3:9:13::Avoid comparisons to zero:HIGH | ||
compare-to-zero:12:3:12:9::Avoid comparisons to zero:HIGH | ||
compare-to-zero:15:3:15:9::Avoid comparisons to zero:HIGH | ||
compare-to-zero:6:3:6:9::"""X is 0"" can be simplified to ""not X"" as 0 is falsey":HIGH | ||
compare-to-zero:9:3:9:13::"""Y is not 0"" can be simplified to ""Y"" as 0 is falsey":HIGH | ||
compare-to-zero:12:3:12:9::"""X == 0"" can be simplified to ""not X"" as 0 is falsey":HIGH | ||
compare-to-zero:15:3:15:9::"""Y != 0"" can be simplified to ""Y"" as 0 is falsey":HIGH |