This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author levkivskyi
Recipients Ruslan Dautkhanov, gvanrossum, levkivskyi
Date 2019-12-31.19:56:41
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1577822201.54.0.866101286494.issue39168@roundup.psfhosted.org>
In-reply-to
Content
This issue came up few times before (although I can't find an issue here on b.p.o., maybe it was on typing-sig list). Although in micro-benchmarks the impact may seem big, in vast majority of applications it is rarely more that a percent or so.

On the other hand, IIRC the only reason `Generic.__new__()` exists is so that one can't write `Generic()` (i.e. instantiate a plain `Generic`). I would be totally fine if we just remove it in 3.9. Hopefully, people already learned what typing is for and don't need so much "protection" against not very meaningful things. Also, the error can be given by static type checkers, there is probably no need for a runtime error.
History
Date User Action Args
2019-12-31 19:56:41levkivskyisetrecipients: + levkivskyi, gvanrossum, Ruslan Dautkhanov
2019-12-31 19:56:41levkivskyisetmessageid: <1577822201.54.0.866101286494.issue39168@roundup.psfhosted.org>
2019-12-31 19:56:41levkivskyilinkissue39168 messages
2019-12-31 19:56:41levkivskyicreate