Update TUPLE_EXPR grammar

This commit is contained in:
Hirokazu Hata 2019-01-13 20:52:25 +09:00
parent 829f668bd7
commit 6efda8f6ce
2 changed files with 8 additions and 2 deletions

View File

@ -2969,7 +2969,11 @@ impl AstNode for TupleExpr {
}
impl TupleExpr {}
impl TupleExpr {
pub fn exprs(&self) -> impl Iterator<Item = &Expr> {
super::children(self)
}
}
// TuplePat
#[derive(Debug, PartialEq, Eq, Hash)]

View File

@ -357,7 +357,9 @@ Grammar(
enum: ["FnDef", "TypeDef", "ConstDef"]
),
"TupleExpr": (),
"TupleExpr": (
collections: [["exprs", "Expr"]]
),
"ArrayExpr": (),
"ParenExpr": (options: ["Expr"]),
"PathExpr": (options: ["Path"]),