On Tue, Sep 25, 2012 at 1:58 PM, Terry Reedy <tjre...@udel.edu> wrote: > On 9/25/2012 11:03 AM, Chris Angelico wrote: >> Instance attributes override (shadow) class attributes. > > > except for (some? all?) special methods
Those names are shadowed too. If you call foo.__len__() and the name is bound on the instance, it will call that function preferentially. It's just that when the special Python machinery calls the method, it skips the instance and goes straight to the class. -- http://mail.python.org/mailman/listinfo/python-list