@@ -2477,37 +2477,39 @@ class Parent:
2477
2477
def f(self, x: int) -> None:
2478
2478
pass
2479
2479
2480
- def g(self, y: int) -> bool :
2481
- return True
2480
+ def g(self, y: int) -> None :
2481
+ pass
2482
2482
2483
2483
class Child(Parent):
2484
2484
def f(self, x: int) -> None: # E: Method "f" is not using @override but is overriding a method in class "__main__.Parent"
2485
2485
pass
2486
2486
2487
2487
@override
2488
- def g(self, y: int) -> bool : #type: ignore # E: Unused "type: ignore" comment # E: "type: ignore" comment without error code
2489
- return True
2488
+ def g(self, y: int) -> None : #type: ignore # E: Unused "type: ignore" comment # E: "type: ignore" comment without error code
2489
+ pass
2490
2490
[builtins fixtures/tuple-simple.pyi]
2491
2491
2492
2492
[case testSpotCheckErrorCodeAllNotUsed]
2493
2493
# This test case exists purely to ensure that the testSpotCheckErrorCodeAll test does not become obsolete.
2494
2494
# (For example, if all the errors expected by testSpotCheckErrorCodeAll get turned on by default, then
2495
- # the testSpotCheckErrorCodeAll test would fail to guarantee the enablement of any additional errors!)
2495
+ # the testSpotCheckErrorCodeAll test would fail to guarantee the enablement of any additional errors!
2496
+ # (hint: if that does happen, breaking this test, then consider changing these two tests to pick *different*,
2497
+ # not-enabled-by-default, error codes.))
2496
2498
2497
2499
from typing_extensions import override
2498
2500
2499
2501
class Parent:
2500
2502
def f(self, x: int) -> None:
2501
2503
pass
2502
2504
2503
- def g(self, y: int) -> bool :
2504
- return True
2505
+ def g(self, y: int) -> None :
2506
+ pass
2505
2507
2506
2508
class Child(Parent):
2507
2509
def f(self, x: int) -> None:
2508
2510
pass
2509
2511
2510
2512
@override
2511
- def g(self, y: int) -> bool : #type: ignore
2512
- return True
2513
+ def g(self, y: int) -> None : #type: ignore
2514
+ pass
2513
2515
[builtins fixtures/tuple-simple.pyi]
0 commit comments