Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

PEP-654: add mention of the syntax options discussion #2103

Merged
merged 2 commits into from
Oct 8, 2021
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
31 changes: 25 additions & 6 deletions pep-0654.rst
Original file line number Diff line number Diff line change
Expand Up @@ -1375,6 +1375,22 @@ clauses. We rejected this because it would be less obvious. The fact that we
are handling exception groups of ``T`` rather than only naked ``Ts`` should be
specified in the same place where we state ``T``.

Alternative syntax options
--------------------------

Alternatives to the ``except*`` syntax were evaluated in a `discussion on python-dev
<http://groups.google.com/g/dev-python/c/G3p9_jovyus>`_, and it was suggested to use
``except group``. Upon careful evaluation this was rejected because the following
would be ambiguous, as it is currently valid syntax where ``group`` is interpreted
as a callable. The same is true for any valid identifier.

.. code-block::

try:
...
except group (T1, T2):
...


Programming Without 'except \*'
===============================
Expand Down Expand Up @@ -1441,12 +1457,15 @@ exception tree whose nodes are exceptions from MultiError, and the ``split()``
API from the design document for MultiError V2. The discussions on python-dev
and elsewhere helped us improve upon the first draft of the PEP in multiple
ways, both the design and the exposition. For this we appreciate all those who
contributed ideas and asked good questions: Matthew Barnett, Ran Benita,
Emily Bowman, Joao Bueno, Baptiste Carvello, Nick Coghlan, Caleb Donovick,
Greg Ewing, Ethan Furman, Larry Hastings, Zac Hatfield-Dodds, Chris Jerdonek,
Jim Jewett, Sven Kunze, Glenn Linderman, Paul Moore, Ivan Pozdeev, Terry Reedy,
Barry Scott, Damian Shaw, Cameron Simpson, Paul Sokolovsky, Steve Stagg,
Marco Sulla, and Petr Viktorin.
contributed ideas and asked good questions: Ammar Askar, Matthew Barnett,
Ran Benita, Emily Bowman, Brandt Bucher, Joao Bueno, Baptiste Carvello,
Rob Cliffe, Nick Coghlan, Steven D'Aprano, Caleb Donovick, Steve Dower,
Greg Ewing, Ethan Furman, Pablo Salgado, Jonathan Goble, Thomas Grainger,
Larry Hastings, Zac Hatfield-Dodds, Chris Jerdonek, Jim Jewett, Sven Kunze,
Łukasz Langa, Glenn Linderman, Paul Moore, Antoine Pitrou, Ivan Pozdeev,
Patrick Reader, Terry Reedy, Sascha Schlemmer, Barry Scott, Mark Shannon,
Damian Shaw, Cameron Simpson, Gregory Smith, Paul Sokolovsky, Calvin Spealman,
Steve Stagg, Victor Stinner, Marco Sulla, Petr Viktorin and Barry Warsaw.
gvanrossum marked this conversation as resolved.
Show resolved Hide resolved


References
Expand Down