difference between class methods and instance methods

Diez B. Roggisch deetsNOSPAM at web.de
Fri Feb 18 08:26:38 EST 2005


> This is badly wrong. John was correct.
> 
> Bound methods get created whenever you reference a method of an instance.
> If you are calling the method then the bound method is destroyed as soon
> as the call returns. You can have as many different bound methods created
> from the same unbound method and the same instance as you want:

That did escape me so far - interesting. Why is it that way? I'd expect that
creating a bound method from the class and then storing it in the objects
dictionary is what happens. 

-- 
Regards,

Diez B. Roggisch



More information about the Python-list mailing list