Instances' __setitem__ methods
Ethan Furman
ethan at stoneleaf.us
Mon Jun 20 23:37:34 EDT 2011
More information about the Python-list mailing list
Mon Jun 20 23:37:34 EDT 2011
- Previous message (by thread): Instances' __setitem__ methods
- Next message (by thread): Instances' __setitem__ methods
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Spencer Pearson wrote: > I was recently trying to implement a dict-like object which would do > some fancy stuff when it was modified, and found that overriding the > __setitem__ method of an instance did not act the way I expected. The __magic__ methods are only looked up on the class, never the instance. ~Ethan~
- Previous message (by thread): Instances' __setitem__ methods
- Next message (by thread): Instances' __setitem__ methods
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
More information about the Python-list mailing list