[Python-ideas] A different kind of context manager

Masklinn masklinn at masklinn.net
Wed Oct 23 17:17:14 CEST 2013


On 2013-10-23, at 16:55 , Kristján Valur Jónsson wrote:

> (CS buffs out there will likely point out to me that this was not an original Matz invention).

You don't need CS buffs to point it out, it was an implementation detail
leaking into semantic incompatibility between types implemented in C and
classes implemented in Python:
http://python-history.blogspot.be/2010/06/new-style-classes.html

Python was fairly unique in having this dichotomy between built-in and
user-defined types[0].

[0] but not anymore, Go has repeated this mistake, amongst others.


More information about the Python-ideas mailing list