diff --git a/src/parser.rs b/src/parser.rs index bff85c6..c085561 100644 --- a/src/parser.rs +++ b/src/parser.rs @@ -119,7 +119,9 @@ impl<'a> Parser<'a> { name, params, body, - }) + }); + + ast; } fn variable(&mut self, ast: &mut AST) { @@ -252,6 +254,8 @@ impl<'a> Parser<'a> { message, newline: true, }); + + ast; } fn if_statement(&mut self, ast: &mut AST) { @@ -305,6 +309,8 @@ impl<'a> Parser<'a> { body: vec![], else_body: None, }); + + ast; } fn while_statement(&mut self, ast: &mut AST) { @@ -462,5 +468,7 @@ impl<'a> Parser<'a> { ast.add_node(ASTNode::Import { module_name: "".to_string() }); + + ast; } }