Skip to content

Commit 5f65700

Browse files
[doc] Add warning for empty sequences in 'use-implicit-booleaness-not-comparison'
1 parent cbef607 commit 5f65700

File tree

3 files changed

+7
-3
lines changed
  • doc/data/messages/u
    • use-implicit-booleaness-not-comparison-to-string
    • use-implicit-booleaness-not-comparison-to-zero
    • use-implicit-booleaness-not-comparison

3 files changed

+7
-3
lines changed
Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
11
Following this check blindly in weakly typed code base can create hard to debug issues. If the value
2-
can be something else that is falsey but not a string (for example ``None``, or ``0``), the code will
2+
can be something else that is falsey but not a string (for example ``None``, an empty sequence, or ``0``),
3+
the code will
34
not be equivalent.
Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
11
Following this check blindly in weakly typed code base can create hard to debug issues. If the value
2-
can be something else that is falsey but not an ``int`` (for example ``None``, or an empty string),
3-
the code will not be equivalent.
2+
can be something else that is falsey but not an ``int`` (for example ``None``, an empty sequence,
3+
or an empty string), the code will not be equivalent.
Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
Following this check blindly in weakly typed code base can create hard to debug issues. If the value
2+
can be something else that is falsey but not a sequence (for example ``None``, an empty string, or ``0``),
3+
the code will not be equivalent.

0 commit comments

Comments
 (0)