]> git.ipfire.org Git - thirdparty/Python/cpython.git/commitdiff
[Enum docs]: fix order of arguments to isinstance() (GH-98542)
authorMiss Islington (bot) <31488909+miss-islington@users.noreply.github.com>
Sat, 22 Oct 2022 11:36:01 +0000 (04:36 -0700)
committerGitHub <noreply@github.com>
Sat, 22 Oct 2022 11:36:01 +0000 (04:36 -0700)
(cherry picked from commit 327fc1c6fa11b007213287cbf46380b7afed9be3)

Co-authored-by: Clément Robert <cr52@protonmail.com>
Doc/library/enum.rst

index 1abd25dc50a777b9aff993b08fc63d2dae039f9a..d666fa96e7cc430223e3a22c181fd9d2c045f934 100644 (file)
@@ -434,7 +434,7 @@ Data Types
 
    .. note:: There are places in the stdlib that check for an exact :class:`str`
              instead of a :class:`str` subclass (i.e. ``type(unknown) == str``
-             instead of ``isinstance(str, unknown)``), and in those locations you
+             instead of ``isinstance(unknown, str)``), and in those locations you
              will need to use ``str(StrEnum.member)``.
 
    .. note::