Message367312
typing._GenericAlias represents two different types: user defined (like List[int]) and special (like List). They have different behavior, and common methods contain special cases.
The proposed PR rewrites the implementation in more object-oriented paradigm: different classes for different behavior. _GenericAlias is split on three classes: user defined (it may be replaced with GenericAlias in future), special, and the base class for common methods. Its subclasses are also split on classes for special types Tuple and Callable and for parametrized Callable[] and Annotated[]. The work is not finished yet and the code is still complex. |
|
Date |
User |
Action |
Args |
2020-04-26 16:35:15 | serhiy.storchaka | set | recipients:
+ serhiy.storchaka, gvanrossum, levkivskyi |
2020-04-26 16:35:15 | serhiy.storchaka | set | messageid: <1587918915.07.0.818996162208.issue40397@roundup.psfhosted.org> |
2020-04-26 16:35:15 | serhiy.storchaka | link | issue40397 messages |
2020-04-26 16:35:14 | serhiy.storchaka | create | |
|