mirror of https://github.com/python/cpython
docs: Fix enum reassign `str` documentation (GH-101507)
This commit is contained in:
parent
0675b8f032
commit
24cbc7a2a0
|
@ -922,6 +922,6 @@ Notes
|
|||
|
||||
or you can reassign the appropriate :meth:`str`, etc., in your enum::
|
||||
|
||||
>>> from enum import IntEnum
|
||||
>>> from enum import Enum, IntEnum
|
||||
>>> class MyIntEnum(IntEnum):
|
||||
... __str__ = IntEnum.__str__
|
||||
... __str__ = Enum.__str__
|
||||
|
|
Loading…
Reference in New Issue