diff options
-rw-r--r-- | src/include/main.h | 0 | ||||
-rw-r--r-- | src/parser.c | 7 |
2 files changed, 6 insertions, 1 deletions
diff --git a/src/include/main.h b/src/include/main.h deleted file mode 100644 index e69de29..0000000 --- a/src/include/main.h +++ /dev/null diff --git a/src/parser.c b/src/parser.c index a7bf1b5..a9ee6d5 100644 --- a/src/parser.c +++ b/src/parser.c @@ -31,7 +31,7 @@ void parser_check_expect(parser_t* parser, int token_type) { // creates the abstract syntax tree tree_t* parser_parse(parser_t* parser) { - return parser_parse_chunks(); + return parser_parse_chunks(parser); } tree_t* parser_parse_token_id(parser_t* parser) { @@ -47,6 +47,11 @@ tree_t* parser_parse_chunk(parser_t* parser) { switch (parser->token->type) { case TOKEN_KEYWORD: { return parser_parse_keyword(parser); + break; + } + default: { + fputs("smthn smthn \"invalid syntax,\" idk.", stderr); + exit(1); } } } |