Skip to content

Commit e79c391

Browse files
gh-118342: [Enum] update docs (GH-137290)
Co-authored-by: Stan Ulbrych <89152624+StanFromIreland@users.noreply.github.com>
1 parent 33d94ab commit e79c391

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

Doc/library/enum.rst

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -947,12 +947,13 @@ Utilities and Decorators
947947
the member's name. Care must be taken if mixing *auto()* with manually
948948
specified values.
949949

950-
*auto* instances are only resolved when at the top level of an assignment:
950+
*auto* instances are only resolved when at the top level of an assignment, either by
951+
itself or as part of a tuple:
951952

952953
* ``FIRST = auto()`` will work (auto() is replaced with ``1``);
953954
* ``SECOND = auto(), -2`` will work (auto is replaced with ``2``, so ``2, -2`` is
954955
used to create the ``SECOND`` enum member;
955-
* ``THREE = [auto(), -3]`` will *not* work (``<auto instance>, -3`` is used to
956+
* ``THREE = [auto(), -3]`` will *not* work (``[<auto instance>, -3]`` is used to
956957
create the ``THREE`` enum member)
957958

958959
.. versionchanged:: 3.11.1

0 commit comments

Comments
 (0)