-
-
Notifications
You must be signed in to change notification settings - Fork 34.7k
Annotated assignment in a match block does not generate SETUP_ANNOTATIONS #105164
Copy link
Copy link
Closed
Labels
3.11only security fixesonly security fixes3.12only security fixesonly security fixes3.13bugs and security fixesbugs and security fixesinterpreter-core(Objects, Python, Grammar, and Parser dirs)(Objects, Python, Grammar, and Parser dirs)triagedThe issue has been accepted as valid by a triager.The issue has been accepted as valid by a triager.type-bugAn unexpected behavior, bug, or errorAn unexpected behavior, bug, or error
Metadata
Metadata
Assignees
Labels
3.11only security fixesonly security fixes3.12only security fixesonly security fixes3.13bugs and security fixesbugs and security fixesinterpreter-core(Objects, Python, Grammar, and Parser dirs)(Objects, Python, Grammar, and Parser dirs)triagedThe issue has been accepted as valid by a triager.The issue has been accepted as valid by a triager.type-bugAn unexpected behavior, bug, or errorAn unexpected behavior, bug, or error
Fields
Give feedbackNo fields configured for issues without a type.
Bug report
Compiling the following code:
generates
There is no
SETUP_ANNOTATIONSopcode generated despite the__annotations__access later on. (Found via google/pytype#1435 - for some reason this does not generate a runtime error, but it does cause issues for tools like pytype.)Your environment
cpython 3.10
Linked PRs