replace mothod for only one object but not for a class
Bruno Desthuilliers
bdesth.quelquechose at free.quelquepart.fr
Tue Oct 14 14:51:15 EDT 2008
Christian Heimes a écrit :
> Bruno Desthuilliers wrote:
>> If the class is a new-style one [1], it just requires invoking the
>> descriptor protocol by yourself to get a bound method, ie:
>
> Another note about new style classes:
> You can NOT overwrite most magic methods (__*__) on the instance. Most
> magic methods are only looked up on the class object.
>
Yes, indeed, I forgot to mention that. Thanks for the precious precision.
More information about the Python-list
mailing list