AST - Removed useless field from Lambda
This commit is contained in:
parent
2881eb5a61
commit
ab46d0bcef
2 changed files with 1 additions and 7 deletions
|
@ -98,8 +98,6 @@ pub enum ExprNode {
|
|||
|
||||
/// A lambda function.
|
||||
Lambda {
|
||||
/// The `fun` token which creates the lambda.
|
||||
token: Token,
|
||||
params: Vec<Token>,
|
||||
body: Vec<StmtNode>,
|
||||
},
|
||||
|
|
|
@ -685,11 +685,7 @@ impl Parser {
|
|||
})
|
||||
} else if let Some(token) = self.expect(&[TokenType::Fun]) {
|
||||
let (params, body) = self.parse_function_info(FunctionKind::Lambda)?;
|
||||
Ok(ast::ExprNode::Lambda {
|
||||
token,
|
||||
params,
|
||||
body,
|
||||
})
|
||||
Ok(ast::ExprNode::Lambda { params, body })
|
||||
} else if let Some(token) =
|
||||
self.expect(&[TokenType::False, TokenType::True, TokenType::Nil])
|
||||
{
|
||||
|
|
Loading…
Reference in a new issue