summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--Doc/library/enum.rst7
1 files changed, 4 insertions, 3 deletions
diff --git a/Doc/library/enum.rst b/Doc/library/enum.rst
index 487dace..57e1f58 100644
--- a/Doc/library/enum.rst
+++ b/Doc/library/enum.rst
@@ -198,11 +198,12 @@ Data Types
>>> some_var = Color.RED
>>> some_var in Color
True
+ >>> Color.RED.value in Color
+ True
- .. note::
+ .. versionchanged:: 3.12
- In Python 3.12 it will be possible to check for member values and not
- just members; until then, a ``TypeError`` will be raised if a
+ Before Python 3.12, a ``TypeError`` is raised if a
non-Enum-member is used in a containment check.
.. method:: EnumType.__dir__(cls)