staticmethod

Jeremy Yallop jeremy at jdyallop.freeserve.co.uk
Tue Feb 25 19:14:36 EST 2003


Andrew Bennetts wrote:
> The problem is that you were trying to make a staticmethod with an unbound
> method, not with the function.  You could also use A.__dict__['foo'] instead
> of A.foo.im_func, I think.

Thanks, that makes sense.  I suppose this falls under "explicit is
better than implicit."

Jeremy.




More information about the Python-list mailing list