My CTO is learning Python....

Bjorn Pettersen BPettersen at
Sat Mar 1 16:53:52 CET 2003

> From: Alex Martelli [mailto:aleax at] 
> Bjorn Pettersen wrote:
>    ...
> > what I don't understand is why a bound method is special 
> > and can be used as a staticmethod, while regular functions 
> > (def/lambda) cannot? Anyone?
> ANY callable except a "regular function" can be "used as a 
> staticmethod" (and it can ONLY be used that way) -- because 
> looking up an attribute in a class's dictionary morphs 
> functions into methods (bound or unbound as appropriate), 
> but it morphs no other types of attribute whatsoever.

Thanks Alex! I can't even remember reading most of the stuff in 3.2
(RefMan)... guess what I'll be doing today :-) Btw., when is the
Nutshell book coming out? I need more good books with proper attention
to detail <wink>.

-- bjorn

More information about the Python-list mailing list