[3.12] GH-111182: Update EnumType.__contains__ docs (GH-111184) (GH-111281)

GH-111182: Update EnumType.__contains__ docs (GH-111184)
(cherry picked from commit c0ea67dd0d)

Co-authored-by: InSync <122007197+InSyncWithFoo@users.noreply.github.com>
This commit is contained in:
Miss Islington (bot) 2023-10-24 19:52:17 +02:00 committed by GitHub
parent b6e508cc86
commit 2a28aa10a8
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -198,11 +198,12 @@ Data Types
>>> some_var = Color.RED >>> some_var = Color.RED
>>> some_var in Color >>> some_var in Color
True 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 Before Python 3.12, a ``TypeError`` is raised if a
just members; until then, a ``TypeError`` will be raised if a
non-Enum-member is used in a containment check. non-Enum-member is used in a containment check.
.. method:: EnumType.__dir__(cls) .. method:: EnumType.__dir__(cls)