is it a bug ?

Sylvain Ferriol sferriol at imag.fr
Mon Oct 23 10:48:52 CEST 2006


hello
can you explain to me what happened:

class toto(object):
   eq = float.__eq__

t = toto()

getattr(t,'eq')
TypeError: descriptor '__eq__' for 'float' objects doesn't apply to 
'toto' object




More information about the Python-list mailing list