summaryrefslogtreecommitdiff
path: root/test/parser_test.c
diff options
context:
space:
mode:
Diffstat (limited to 'test/parser_test.c')
-rw-r--r--test/parser_test.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/test/parser_test.c b/test/parser_test.c
index ce77828..2d749da 100644
--- a/test/parser_test.c
+++ b/test/parser_test.c
@@ -140,9 +140,8 @@ test_parse_arithmetic_expression(const MunitParameter params[], void *user_data_
make_lexer_from_static_src(&lexer, "1 + 3 * 3 / 2 - 1");
parser_init(&parser, &lexer, scope);
- ast_node_t *ast_expression = ast_node_new();
- bool parsed = parser_parse_expression(&parser, ast_expression);
- assert_true(parsed);
+ ast_node_t *ast_expression = parser_parse_expression(&parser);
+ assert_not_null(ast_expression);
ast_node_t *exp1 = ast_expression;
{