-
-
Notifications
You must be signed in to change notification settings - Fork 32.5k
Closed
Labels
interpreter-core(Objects, Python, Grammar, and Parser dirs)(Objects, Python, Grammar, and Parser dirs)topic-typingtype-featureA feature request or enhancementA feature request or enhancement
Description
Feature or enhancement
Proposal:
coroutine and generator should be subscriptable at runtime as they already are at type time
>>> import types
>>> types.CoroutineType[None, None, int]
TypeError: type 'coroutine' is not subscriptable
Has this already been discussed elsewhere?
This is a minor feature, which does not need previous discussion elsewhere
Links to previous discussion of this feature:
python/typing#1480 is where this stemmed from
Linked PRs
Metadata
Metadata
Assignees
Labels
interpreter-core(Objects, Python, Grammar, and Parser dirs)(Objects, Python, Grammar, and Parser dirs)topic-typingtype-featureA feature request or enhancementA feature request or enhancement