We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 46407fe commit c0ea67dCopy full SHA for c0ea67d
Doc/library/enum.rst
@@ -198,11 +198,12 @@ Data Types
198
>>> some_var = Color.RED
199
>>> some_var in Color
200
True
201
+ >>> Color.RED.value in Color
202
+ True
203
- .. note::
204
+ .. versionchanged:: 3.12
205
- 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
206
+ Before Python 3.12, a ``TypeError`` is raised if a
207
non-Enum-member is used in a containment check.
208
209
.. method:: EnumType.__dir__(cls)
0 commit comments