Ivan Levkivskyi <levkivs...@gmail.com> added the comment:

This is an intentional change. It would be a bad idea to use `__name__` instead 
of what is currently `_name`, because semantics is subtly different. Also the 
fact that types in typing module used to be actual class objects was an 
implementation detail (also typing module is still provisional).

The problematic part here is that special types and generic type aliases are 
still documented as _classes_ in 
https://docs.python.org/3.7/library/typing.html, I think this needs to be 
updated. (Plus we should add an explicit note somewhere in the docs that static 
types and runtime classes should not be confused.)

----------

_______________________________________
Python tracker <rep...@bugs.python.org>
<https://bugs.python.org/issue34422>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com

Reply via email to