We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 016eda6 commit 2182e5dCopy full SHA for 2182e5d
test-data/unit/check-narrowing.test
@@ -2472,6 +2472,15 @@ while True:
2472
x = B()
2473
[builtins fixtures/primitives.pyi]
2474
2475
+[case testAvoidFalseNonOverlappingEqualityCheckInLoop3]
2476
+# flags: --strict-equality
2477
+
2478
+for y in [1.0]:
2479
+ if y is not None or y != "None": # E: Non-overlapping equality check (left operand type: "float", right operand type: "Literal['None']")
2480
+ ...
2481
2482
+[builtins fixtures/primitives.pyi]
2483
2484
[case testNarrowPromotionsInsideUnions1]
2485
2486
from typing import Union
0 commit comments