Skip to content

Commit 1904d09

Browse files
committed
Allow named expression in subscript: a[b := c]
Signed-off-by: Anders Kaseorg <andersk@mit.edu>
1 parent 201d085 commit 1904d09

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

‎parser/python.lalrpop‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1023,7 +1023,7 @@ SubscriptList: ast::Expr = {
10231023
};
10241024

10251025
Subscript: ast::Expr = {
1026-
Test<"all">,
1026+
NamedExpressionTest,
10271027
<location:@L> <e1:Test<"all">?> ":" <e2:Test<"all">?> <e3:SliceOp?> <end_location:@R> => {
10281028
let lower = e1.map(Box::new);
10291029
let upper = e2.map(Box::new);

0 commit comments

Comments
 (0)