summaryrefslogtreecommitdiffstats
path: root/Lib/_abcoll.py
diff options
context:
space:
mode:
Diffstat (limited to 'Lib/_abcoll.py')
-rw-r--r--Lib/_abcoll.py5
1 files changed, 3 insertions, 2 deletions
diff --git a/Lib/_abcoll.py b/Lib/_abcoll.py
index a60d91e..e9f06a5 100644
--- a/Lib/_abcoll.py
+++ b/Lib/_abcoll.py
@@ -376,8 +376,9 @@ class Mapping(Sized, Iterable, Container):
return ValuesView(self)
def __eq__(self, other):
- return isinstance(other, Mapping) and \
- dict(self.items()) == dict(other.items())
+ if not isinstance(other, Mapping):
+ return NotImplemented
+ return dict(self.items()) == dict(other.items())
def __ne__(self, other):
return not (self == other)