From dd4c895dd27110f738c991ff53d683479a1b285f Mon Sep 17 00:00:00 2001 From: NeilBrown Date: Sun, 11 May 2014 09:40:32 +1000 Subject: [PATCH] pargergen: don't ignore first token When parsing the grammar we currently skip the first token by mistake. It is often a TK_newline so not much is lost. But not always... Signed-off-by: NeilBrown --- csrc/parsergen.mdc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/csrc/parsergen.mdc b/csrc/parsergen.mdc index 1bb813e..aae8a3f 100644 --- a/csrc/parsergen.mdc +++ b/csrc/parsergen.mdc @@ -545,7 +545,7 @@ Now we are ready to read in the grammar. }; struct token_state *state = token_open(code, &conf); - struct token tk = token_next(state); + struct token tk; struct symbol *head = NULL; struct grammar *g; char *err = NULL; -- 2.43.0