mirror of
https://github.com/RustPython/Parser.git
synced 2025-07-18 02:25:25 +00:00
Allow named expression in set comprehension: {a := b for c in d}
Signed-off-by: Anders Kaseorg <andersk@mit.edu>
This commit is contained in:
parent
1d98291839
commit
472d664c95
1 changed files with 1 additions and 1 deletions
|
@ -1185,7 +1185,7 @@ Atom<Goal>: ast::Expr = {
|
||||||
custom: (),
|
custom: (),
|
||||||
node: ast::ExprKind::Set { elts }
|
node: ast::ExprKind::Set { elts }
|
||||||
},
|
},
|
||||||
<location:@L> "{" <elt:Test<"all">> <generators:CompFor> "}" <end_location:@R> => {
|
<location:@L> "{" <elt:NamedExpressionTest> <generators:CompFor> "}" <end_location:@R> => {
|
||||||
ast::Expr {
|
ast::Expr {
|
||||||
location,
|
location,
|
||||||
end_location: Some(end_location),
|
end_location: Some(end_location),
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue