From be3c2fea35de9bbdd5e3c9328fa413ed04ba7d6b Mon Sep 17 00:00:00 2001 From: Ethan Furman Date: Wed, 13 Nov 2013 14:25:45 -0800 Subject: removed Enum.__eq__ as it added nothing --- Lib/enum.py | 5 ----- 1 file changed, 5 deletions(-) (limited to 'Lib/enum.py') diff --git a/Lib/enum.py b/Lib/enum.py index 7ca85035deb..7d58f8d17a6 100644 --- a/Lib/enum.py +++ b/Lib/enum.py @@ -447,11 +447,6 @@ class Enum(metaclass=EnumMeta): return (['__class__', '__doc__', '__module__', 'name', 'value'] + added_behavior) - def __eq__(self, other): - if type(other) is self.__class__: - return self is other - return NotImplemented - def __format__(self, format_spec): # mixed-in Enums should use the mixed-in type's __format__, otherwise # we can get strange results with the Enum name showing up instead of -- cgit v1.2.3