-
-
Notifications
You must be signed in to change notification settings - Fork 32.4k
Closed
Labels
3.10only security fixesonly security fixesinterpreter-core(Objects, Python, Grammar, and Parser dirs)(Objects, Python, Grammar, and Parser dirs)type-bugAn unexpected behavior, bug, or errorAn unexpected behavior, bug, or error
Description
Code snippet:
class C(list[int]): ...
On Python 3.9:
>>> class C(list[*a]): ...
File "<stdin>", line 1
class C(list[*a]): ...
^
SyntaxError: invalid syntax
>>>
On Python 3.10:
>>> class C(list[*a]): ...
File "<stdin>", line 1
class C(list[*a]): ...
^
SyntaxError: expected ':'
>>>
I'd have expected it to point directly at the *
in both cases.
Metadata
Metadata
Assignees
Labels
3.10only security fixesonly security fixesinterpreter-core(Objects, Python, Grammar, and Parser dirs)(Objects, Python, Grammar, and Parser dirs)type-bugAn unexpected behavior, bug, or errorAn unexpected behavior, bug, or error