summaryrefslogtreecommitdiffstats
path: root/Lib/enum.py
diff options
context:
space:
mode:
authorEthan Furman <ethan@stoneleaf.us>2016-01-15 23:01:33 (GMT)
committerEthan Furman <ethan@stoneleaf.us>2016-01-15 23:01:33 (GMT)
commit60255b67b986d4c448153bef16755599afbfdaa2 (patch)
tree40835fb60bb87fcbbab7418e5230eeaa64d47f46 /Lib/enum.py
parent43cfd8240c274b2f4cf0588f3defae83e7379a55 (diff)
downloadcpython-60255b67b986d4c448153bef16755599afbfdaa2.zip
cpython-60255b67b986d4c448153bef16755599afbfdaa2.tar.gz
cpython-60255b67b986d4c448153bef16755599afbfdaa2.tar.bz2
revert change 87a9dff5106c: pure Enum members again evaluate to True;
update Finer Points section of docs to cover boolean evaluation; add more tests for pure and mixed boolean evaluation
Diffstat (limited to 'Lib/enum.py')
-rw-r--r--Lib/enum.py3
1 files changed, 0 insertions, 3 deletions
diff --git a/Lib/enum.py b/Lib/enum.py
index 35a9c77..ac89d6b 100644
--- a/Lib/enum.py
+++ b/Lib/enum.py
@@ -482,9 +482,6 @@ class Enum(metaclass=EnumMeta):
def __str__(self):
return "%s.%s" % (self.__class__.__name__, self._name_)
- def __bool__(self):
- return bool(self._value_)
-
def __dir__(self):
added_behavior = [
m