From: Miss Islington (bot) <31488909+miss-islington@users.noreply.github.com> Date: Tue, 11 Oct 2022 16:22:04 +0000 (-0700) Subject: gh-98172: Fix formatting in `except*` docs (GH-98173) X-Git-Tag: v3.11.0~132 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=e0260d03f78b2db31f056e49d601739e036055b6;p=thirdparty%2FPython%2Fcpython.git gh-98172: Fix formatting in `except*` docs (GH-98173) (cherry picked from commit 5ecf961640192a2192383aa20e1e93dcdf23c9b6) Co-authored-by: Jelle Zijlstra --- diff --git a/Doc/reference/compound_stmts.rst b/Doc/reference/compound_stmts.rst index 751c7c2dbcf2..6a176b74b1b3 100644 --- a/Doc/reference/compound_stmts.rst +++ b/Doc/reference/compound_stmts.rst @@ -340,17 +340,17 @@ one except* clause, the first that matches it. :: +-+---------------- 1 ---------------- | ValueError: 1 +------------------------------------ - >>> - Any remaining exceptions that were not handled by any except* clause - are re-raised at the end, combined into an exception group along with - all exceptions that were raised from within except* clauses. +Any remaining exceptions that were not handled by any :keyword:`!except*` +clause are re-raised at the end, combined into an exception group along with +all exceptions that were raised from within :keyword:`!except*` clauses. - An except* clause must have a matching type, and this type cannot be a - subclass of :exc:`BaseExceptionGroup`. It is not possible to mix except - and except* in the same :keyword:`try`. :keyword:`break`, - :keyword:`continue` and :keyword:`return` cannot appear in an except* - clause. +An :keyword:`!except*` clause must have a matching type, +and this type cannot be a subclass of :exc:`BaseExceptionGroup`. +It is not possible to mix :keyword:`except` and :keyword:`!except*` +in the same :keyword:`try`. +:keyword:`break`, :keyword:`continue` and :keyword:`return` +cannot appear in an :keyword:`!except*` clause. .. index::