diff options
author | Preston Pan <preston@nullring.xyz> | 2023-01-03 00:27:06 -0800 |
---|---|---|
committer | Preston Pan <preston@nullring.xyz> | 2023-01-03 00:27:06 -0800 |
commit | 9f342255a2260480701cc2ac2d0c623d4aba1348 (patch) | |
tree | 6ecd1332032eb09fd28aacab7418da9a5882cb94 /src/include/parser.h | |
parent | 64feef1b9ea72adf7ba32998e9dca7d507607498 (diff) |
add some comments; fix some bugs in advance
Diffstat (limited to 'src/include/parser.h')
-rw-r--r-- | src/include/parser.h | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/src/include/parser.h b/src/include/parser.h index 97a7fd9..64ae792 100644 --- a/src/include/parser.h +++ b/src/include/parser.h @@ -13,6 +13,7 @@ typedef struct { int i; int size; bool finished; + bool is_global; } parser_t; parser_t *init_parser(lexer_t *lexer); @@ -21,7 +22,7 @@ void parser_error(parser_t *parser); void parser_move(parser_t *parser); -void parser_eat(parser_t *parser, token_t *token); +void parser_eat(parser_t *parser, int type); ast_t *parse_string(parser_t *parser); @@ -39,9 +40,7 @@ ast_t *parse_symbol(parser_t *parser); ast_t *parse_function(parser_t *parser); -ast_t *parse_list(parser_t *parser); - -ast_t *parse_bind(parser_t *parser); +void parse_bind(parser_t *parser); ast_t *parse_expr(parser_t *parser); |