[Python-ideas] Re: Generics alternative syntax

2022-02-08 Thread James H-B
I really like the idea as a whole presented here. I have a few concerns here though: 1. The support for constraints overlaps with union which is undesireable, Jelle has previously suggested using TypeVar in (constraint1, constraint2, ...) which I think is much nicer. 2. The syntax for defining c

[Python-ideas] Re: Reusing more builtins for type-hinting

2021-10-01 Thread James H-B
FYI type[Something] is already valid as it was implemented in PEP 585 and is prefered over typing.Type[Something]. ___ Python-ideas mailing list -- python-ideas@python.org To unsubscribe send an email to python-ideas-le...@python.org https://mail.python.