https://github.com/python/cpython/commit/e565d12acb8fd14ad4432c25daf79882794cca60
commit: e565d12acb8fd14ad4432c25daf79882794cca60
branch: 3.15
author: Miss Islington (bot) <[email protected]>
committer: StanFromIreland <[email protected]>
date: 2026-05-27T16:24:47+01:00
summary:

[3.15] gh-149861: Fix rule in match statement `case_block` PEG grammar 
(GH-149908)

(cherry picked from commit 99c254e2f79a4197524bef61bf0d12251ee273e6)

Co-authored-by: Ivy Xu <[email protected]>

files:
M Doc/reference/compound_stmts.rst

diff --git a/Doc/reference/compound_stmts.rst b/Doc/reference/compound_stmts.rst
index a819c41d834aa70..63baefd33e88c50 100644
--- a/Doc/reference/compound_stmts.rst
+++ b/Doc/reference/compound_stmts.rst
@@ -620,7 +620,7 @@ The match statement is used for pattern matching.  Syntax:
    match_stmt: 'match' `subject_expr` ":" NEWLINE INDENT `case_block`+ DEDENT
    subject_expr: `flexible_expression` "," [`flexible_expression_list` [',']]
                : | `assignment_expression`
-   case_block: 'case' `patterns` [`guard`] ":" `!block`
+   case_block: 'case' `patterns` [`guard`] ":" `suite`
 
 .. note::
    This section uses single quotes to denote

_______________________________________________
Python-checkins mailing list -- [email protected]
To unsubscribe send an email to [email protected]
https://mail.python.org/mailman3//lists/python-checkins.python.org
Member address: [email protected]

Reply via email to