diff options
author | Xtreak <tir.karthi@gmail.com> | 2019-02-01 21:40:16 (GMT) |
---|---|---|
committer | Emily Morehouse <emilyemorehouse@gmail.com> | 2019-02-01 21:40:16 (GMT) |
commit | d4fceaafb8e3f8700d9ec6ab37a51e903392f74f (patch) | |
tree | fb3681a954e8d42a3a3161ad38eebcb4eeaf9884 /Grammar | |
parent | 85d83ec7c99727476c79feb5c34c65264a99144e (diff) | |
download | cpython-d4fceaafb8e3f8700d9ec6ab37a51e903392f74f.zip cpython-d4fceaafb8e3f8700d9ec6ab37a51e903392f74f.tar.gz cpython-d4fceaafb8e3f8700d9ec6ab37a51e903392f74f.tar.bz2 |
bpo-35877: Make parenthesis optional for named expression in while statement (GH-11724)
* Add parenthesis optional in named expressions for while statement
* Add NEWS entry
Diffstat (limited to 'Grammar')
-rw-r--r-- | Grammar/Grammar | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/Grammar/Grammar b/Grammar/Grammar index e65a688..a425978 100644 --- a/Grammar/Grammar +++ b/Grammar/Grammar @@ -72,7 +72,7 @@ assert_stmt: 'assert' test [',' test] compound_stmt: if_stmt | while_stmt | for_stmt | try_stmt | with_stmt | funcdef | classdef | decorated | async_stmt async_stmt: 'async' (funcdef | with_stmt | for_stmt) if_stmt: 'if' namedexpr_test ':' suite ('elif' namedexpr_test ':' suite)* ['else' ':' suite] -while_stmt: 'while' test ':' suite ['else' ':' suite] +while_stmt: 'while' namedexpr_test ':' suite ['else' ':' suite] for_stmt: 'for' exprlist 'in' testlist ':' [TYPE_COMMENT] suite ['else' ':' suite] try_stmt: ('try' ':' suite ((except_clause ':' suite)+ |