* data/glr.c (YYRHSLOC): Move its definition next to its uses.
authorAkim Demaille <akim@epita.fr>
Mon, 25 Oct 2004 10:37:35 +0000 (10:37 +0000)
committerAkim Demaille <akim@epita.fr>
Mon, 25 Oct 2004 10:37:35 +0000 (10:37 +0000)
commite342c3beaf9d73616e8ff6fe005b97f3a72c0476
treea284110e058128d1fbff93de80f7fd5d68bb8dd7
parent93602febc0fc0d6e73bf3ebdab56527c02b749e9
* data/glr.c (YYRHSLOC): Move its definition next to its uses.
Introduce another definition to address simple location arrays.
(yyGLRStack): New member: yyerror_range.
(yyrecoverSyntaxError, yyparse): Update it.
(yyrecoverSyntaxError): Use it when shifting the error token to
have an accurate range, equivalent to the one computed by both
yacc.c and lalr1.cc.
* tests/cxx-type.at (_AT_TEST_GLR_CXXTYPES): Change its yylex so
that column numbers start at column 0, as per GNU Coding
Standards, the others tests, and the doc.
(_AT_RESOLVED_GLR_OUTPUT_WITH_LOC, _AT_AMBIG_GLR_OUTPUT_WITH_LOC):
Adjust to the above change (first column is 0).
And adjust the location of the "<error>", now covering the whole
line.
ChangeLog
NEWS
data/glr.c
tests/cxx-type.at