diff options
Diffstat (limited to 'src/parser.c')
-rw-r--r-- | src/parser.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/src/parser.c b/src/parser.c index 92e9ccf..7f174a5 100644 --- a/src/parser.c +++ b/src/parser.c @@ -212,6 +212,8 @@ ast_t *parse_all(parser_t *parser) { int i = 0; while (t != NULL) { cur = parse_expr(parser); + if (cur == NULL) + continue; i++; asts = realloc(asts, i * sizeof(ast_t *)); asts[i - 1] = cur; |