From 55caf0cbe24d20f788b9806b76e2e023975e2474 Mon Sep 17 00:00:00 2001 From: Guido van Rossum Date: Sat, 15 Aug 2020 15:34:19 -0700 Subject: [PATCH] PEP 622: Adopt a few clarifications (only) from #1564 --- pep-0622.rst | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/pep-0622.rst b/pep-0622.rst index 0d81853ee..97a0d91b0 100644 --- a/pep-0622.rst +++ b/pep-0622.rst @@ -1517,8 +1517,8 @@ ambiguous with capture patterns. Five other alternatives were considered: disambiguate grouping in patterns, e.g. in ``Point(x, y=(y := complex()))``. -* Introduce a special symbol, for example ``.``, ``$``, or ``^`` to - indicate that a given name is a constant to be matched against, not +* Introduce a special symbol, for example ``.``, ``?``, ``$``, or ``^`` to + indicate that a given name is a value to be matched against, not to be assigned to. An earlier version of this proposal used a leading-dot rule:: @@ -1554,7 +1554,9 @@ ambiguous with capture patterns. Five other alternatives were considered: * The authors are not aware of any other language that adorns captures in this way. - * None of the proposed syntaxes have any precedent in Python. + * None of the proposed syntaxes have any precedent in Python; + no other place in Python that binds names (e.g. ``import``, + ``def``, ``for``) uses special marker syntax. * It would break the syntactic parallels of the current grammar::