Skip to content

Commit 03dedfe

Browse files
committed
__slots__ in list.pyi caused several failures
1 parent 95fdb41 commit 03dedfe

File tree

2 files changed

+1
-7
lines changed

2 files changed

+1
-7
lines changed

test-data/unit/check-classes.test

-5
Original file line numberDiff line numberDiff line change
@@ -1000,11 +1000,6 @@ class C(P):
10001000
x = ['a'] # E: List item 0 has incompatible type "str"; expected "int"
10011001
[builtins fixtures/list.pyi]
10021002

1003-
[case testClassSlotsAttributeWithTypeInference]
1004-
class P:
1005-
__slots__ = []
1006-
[builtins fixtures/list.pyi]
1007-
10081003
[case testAccessingGenericClassAttribute]
10091004
from typing import Generic, TypeVar
10101005
T = TypeVar('T')

test-data/unit/fixtures/list.pyi

+1-2
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,10 @@
11
# Builtins stub used in list-related test cases.
22

3-
from typing import TypeVar, Generic, Iterable, Iterator, Union, Sequence, overload
3+
from typing import TypeVar, Generic, Iterable, Iterator, Sequence, overload
44

55
T = TypeVar('T')
66

77
class object:
8-
__slots__: Union['str', Iterable['str']]
98
def __init__(self) -> None: pass
109

1110
class type: pass

0 commit comments

Comments
 (0)