]> granicus.if.org Git - python/commit
use a invalid name for the __class__ closure for super() (closes #12370)
authorBenjamin Peterson <benjamin@python.org>
Mon, 20 Jun 2011 00:42:22 +0000 (19:42 -0500)
committerBenjamin Peterson <benjamin@python.org>
Mon, 20 Jun 2011 00:42:22 +0000 (19:42 -0500)
commitf5ff22329b3a4838054dfadfad74fc5a0519cbb2
treecbf644106089a69d028c954e246dab129b3d02cd
parent019d0f27a3fc8d4daa7caea8c041cd26d5873950
use a invalid name for the __class__ closure for super() (closes #12370)

This prevents the assignment of __class__ in the class body from breaking
super. (Although a determined person could do locals()["@__class__"] = 4)
Lib/test/test_super.py
Misc/NEWS
Objects/typeobject.c
Python/compile.c
Python/symtable.c