lazr-developers team mailing list archive
-
lazr-developers team
-
Mailing list archive
-
Message #00039
[Bug 331919] Re: delegates() should provide __eq__ and __ne__ operators.
I changed the subject and description because the original was a
misunderstanding with my reviewer.
** Summary changed:
- delegates() should set the context automatically.
+ delegates() should provide __eq__ and __ne__ operators.
** Description changed:
- For delegates() to work properly, each class needs to set the context
- explicitely in the constructor. It seems like this routine action could
- be done automatically so that it cannot be ommited/forgotten.
+ It would be very useful if delegates would add these to a class:
+
+ def __eq__(self, other):
+ return (self.context == other.context)
+
+ def __ne__(self, other):
+ return not (self == other)
--
delegates() should provide __eq__ and __ne__ operators.
https://bugs.launchpad.net/bugs/331919
You received this bug notification because you are a member of LAZR
Developers, which is the registrant for lazr.delegates.
Status in lazr.delegates: New
Bug description:
It would be very useful if delegates would add these to a class:
def __eq__(self, other):
return (self.context == other.context)
def __ne__(self, other):
return not (self == other)
References