Skip to content

Commit 90d5c9b

Browse files
authored
gh-92120: The docstring of enum.Enum is invalid in reST (GH-92122)
Closes #92120
1 parent dc8a868 commit 90d5c9b

File tree

2 files changed

+8
-7
lines changed

2 files changed

+8
-7
lines changed

Lib/enum.py

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1054,20 +1054,20 @@ class Enum(metaclass=EnumType):
10541054
10551055
Access them by:
10561056
1057-
- attribute access::
1057+
- attribute access:
10581058
1059-
>>> Color.RED
1060-
<Color.RED: 1>
1059+
>>> Color.RED
1060+
<Color.RED: 1>
10611061
10621062
- value lookup:
10631063
1064-
>>> Color(1)
1065-
<Color.RED: 1>
1064+
>>> Color(1)
1065+
<Color.RED: 1>
10661066
10671067
- name lookup:
10681068
1069-
>>> Color['RED']
1070-
<Color.RED: 1>
1069+
>>> Color['RED']
1070+
<Color.RED: 1>
10711071
10721072
Enumerations can be iterated over, and know how many members they have:
10731073
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
Fix reStructuredText syntax errors in docstrings in the :mod:`enum` module.

0 commit comments

Comments
 (0)