> How can I understand the output of bison's debug output ??
such as
--(end of buffer or a NUL)
--accepting rule at line 95 ("int")
--accepting rule at line 173 (" ")
--accepting rule at line 112 ("x")
--accepting rule at line 173 (" ")
--accepting rule at line 146 (";")
--accepting rule at line 174 ("
")
--accepting rule at line 103 ("struct")
--accepting rule at line 173 (" ")
--accepting rule at line 112 ("x")
--accepting rule at line 147 ("{")
--accepting rule at line 174 ("
")
--accepting rule at line 95 ("int")
--accepting rule at line 173 (" ")
--accepting rule at line 112 ("a")
--accepting rule at line 146 (";")
--accepting rule at line 174 ("
")
--accepting rule at line 95 ("int")
--accepting rule at line 173 (" ")
--accepting rule at line 112 ("b")
--accepting rule at line 146 (";")
--accepting rule at line 174 ("
")
--accepting rule at line 149 ("}")
--accepting rule at line 146 (";")
--(end of buffer or a NUL)
--accepting rule at line 174 ("
")
--(end of buffer or a NUL)
--EOF (start condition 0)
--(end of buffer or a NUL)
--EOF (start condition 0)
I think this track the rule which is accepted current .
but what the " at line xxxx" means ?
what file the "at line xxxx" means ?
I can't find the corresponding description at line xxx in file
"grammer.output" !!!
Help
or "grammer.ypp" file
_______________________________________________
help-bison@gnu.org http://lists.gnu.org/mailman/listinfo/help-bison
It seems the trace of the lexer!
--accepting rule at line 95 ("int")
means that in your flex file there is the definition of "int" token at line 95.
To enable the parser's tracing on stderr you have to set
yydebug=1;
Luca
_______________________________________________
help-bison@gnu.org http://lists.gnu.org/mailman/listinfo/help-bison