Skip to content

Commit 8af8d14

Browse files
committed
Add test case
1 parent b7a4eae commit 8af8d14

File tree

1 file changed

+9
-0
lines changed

1 file changed

+9
-0
lines changed

mypy/test/data/check-inference.test

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1045,6 +1045,15 @@ a()
10451045
[builtins fixtures/list.py]
10461046
[out]
10471047

1048+
[case testInferListInitializedToEmptyAndMultipleAssignment]
1049+
a, b = [], []
1050+
a.append(1)
1051+
b.append('')
1052+
a() # E: List[int] not callable
1053+
b() # E: List[str] not callable
1054+
[builtins fixtures/list.py]
1055+
[out]
1056+
10481057
[case testInferListInitializedToEmptyInFunction]
10491058
def f() -> None:
10501059
a = []

0 commit comments

Comments
 (0)