Refactor parser header

Make separate lexer, stack and parser structs.
This commit is contained in:
Max Brunsfeld 2014-03-13 00:43:23 -07:00
parent 05a5f9c124
commit 0dc3a95d0c
11 changed files with 361 additions and 276 deletions

View file

@ -24,7 +24,7 @@ SYMBOL_NAMES {
"token2",
};
static const ts_symbol * ts_recover(ts_state state, ts_state *to_state, size_t *count) {
RECOVER_FN() {
switch (state) {
case 6:
RECOVER(7, 1, EXPECT({ts_aux_sym_token2}));

View file

@ -32,7 +32,7 @@ SYMBOL_NAMES {
"repeat_helper2",
};
static const ts_symbol * ts_recover(ts_state state, ts_state *to_state, size_t *count) {
RECOVER_FN() {
switch (state) {
case 3:
RECOVER(52, 2, EXPECT({ts_sym_comma, ts_sym_right_brace}));