File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -644,12 +644,14 @@ Instead of the normal ``%``\ -based substitutions, Templates support ``$``\
644644* ``$$ `` is an escape; it is replaced with a single ``$ ``.
645645
646646* ``$identifier `` names a substitution placeholder matching a mapping key of
647- ``"identifier" ``. By default, ``"identifier" `` must spell a Python
648- identifier. The first non-identifier character after the ``$ `` character
649- terminates this placeholder specification.
650-
651- * ``${identifier} `` is equivalent to ``$identifier ``. It is required when valid
652- identifier characters follow the placeholder but are not part of the
647+ ``"identifier" ``. By default, ``"identifier" `` is restricted to any
648+ case-insensitive ASCII alphanumeric string (including underscores) that
649+ starts with an underscore or ASCII letter. The first non-identifier
650+ character after the ``$ `` character terminates this placeholder
651+ specification.
652+
653+ * ``${identifier} `` is equivalent to ``$identifier ``. It is required when
654+ valid identifier characters follow the placeholder but are not part of the
653655 placeholder, such as ``"${noun}ification" ``.
654656
655657Any other appearance of ``$ `` in the string will result in a :exc: `ValueError `
Original file line number Diff line number Diff line change @@ -13,6 +13,12 @@ Core and Builtins
1313Library
1414-------
1515
16+ Documentation
17+ -------------
18+
19+ - Issue #24351: Clarify what is meant by "identifier" in the context of
20+ string.Template instances.
21+
1622
1723What's New in Python 3.5.0 beta 3?
1824==================================
You can’t perform that action at this time.
0 commit comments