New submission from Antoine Pitrou <pit...@free.fr>: >>> class Foo: ... __slots__ = ['foo'] ... foo = None ... >>> x = Foo() >>> x.foo >>> x.foo = 5 Traceback (most recent call last): File "<stdin>", line 1, in <module> AttributeError: 'Foo' object attribute 'foo' is read-only
---------- components: Interpreter Core messages: 142232 nosy: benjamin.peterson, pitrou priority: normal severity: normal status: open title: strange interaction between __slots__ and class-level attributes type: behavior versions: Python 3.2, Python 3.3 _______________________________________ Python tracker <rep...@bugs.python.org> <http://bugs.python.org/issue12766> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com