diff --git a/pytools/__init__.py b/pytools/__init__.py index 2fd39f9417a3e8b6405827fd33dd3fb204ce6a6c..225e2dfadcb2ba69aa8960d7266031eecd1b3d6f 100644 --- a/pytools/__init__.py +++ b/pytools/__init__.py @@ -463,6 +463,8 @@ class Record(RecordWithoutPickling): setattr(self, key, value) def __eq__(self, other): + if self is other: + return True return (self.__class__ == other.__class__ and self.__getstate__() == other.__getstate__())