Re: __eq__ problem with subclasses

2008-08-23 Thread Daniel Israel
Scott David Daniels wrote: Daniel Israel wrote: I am very confused by the following behavior. I have a base class which defines __eq__. I then have a subclass which does not. When I evaluate the expression a==b, where a and b are elements of these classes, __eq__ is always called with the

__eq__ problem with subclasses

2008-08-22 Thread Daniel Israel
I am very confused by the following behavior. I have a base class which defines __eq__. I then have a subclass which does not. When I evaluate the expression a==b, where a and b are elements of these classes, __eq__ is always called with the subclass as the first argument, regardless of the o