Skip to content

Commit

Permalink
bpo-40204: Fix duplicated productionlist names in the doc (GH-21900)
Browse files Browse the repository at this point in the history
Sphinx 3 disallows having more than one productionlist markup with
the same name. Simply remove names in this case, since names are not
shown anyway. For example, fix the Sphinx 3 warning:

Doc/reference/introduction.rst:96: duplicate token description
of *:name, other instance in reference/expressions
  • Loading branch information
vstinner authored Aug 17, 2020
1 parent fbf43f0 commit 1abeda8
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion Doc/library/string.rst
Original file line number Diff line number Diff line change
Expand Up @@ -308,7 +308,7 @@ non-empty format specification typically modifies the result.

The general form of a *standard format specifier* is:

.. productionlist:: sf
.. productionlist::
format_spec: [[`fill`]`align`][`sign`][#][0][`width`][`grouping_option`][.`precision`][`type`]
fill: <any character>
align: "<" | ">" | "=" | "^"
Expand Down
2 changes: 1 addition & 1 deletion Doc/reference/introduction.rst
Original file line number Diff line number Diff line change
Expand Up @@ -93,7 +93,7 @@ Notation
The descriptions of lexical analysis and syntax use a modified BNF grammar
notation. This uses the following style of definition:

.. productionlist:: *
.. productionlist::
name: `lc_letter` (`lc_letter` | "_")*
lc_letter: "a"..."z"

Expand Down

0 comments on commit 1abeda8

Please sign in to comment.