mirror of
https://git.savannah.gnu.org/git/bison.git
synced 2026-03-09 12:23:04 +00:00
%name-prefix is broken.
* src/files.c (spec_name_prefix): Initialize to NULL, not to "yy". Adjust all dependencies. * tests/headers.at (export YYLTYPE): Strengthen this test: use %name-prefix. Renaming yylval but not yylloc is not consistent. Now we do. * src/bison.simple: Prefix yylloc if used. * doc/bison.texinfo (Decl Summary): Document that.
This commit is contained in:
@@ -3289,10 +3289,10 @@ accurate parse error messages.
|
||||
Rename the external symbols used in the parser so that they start with
|
||||
@var{prefix} instead of @samp{yy}. The precise list of symbols renamed
|
||||
is @code{yyparse}, @code{yylex}, @code{yyerror}, @code{yynerrs},
|
||||
@code{yylval}, @code{yychar} and @code{yydebug}. For example, if you
|
||||
use @samp{%name-prefix="c_"}, the names become @code{c_parse},
|
||||
@code{c_lex}, and so on. @xref{Multiple Parsers, ,Multiple Parsers in
|
||||
the Same Program}.
|
||||
@code{yylval}, @code{yychar}, @code{yydebug}, and possible
|
||||
@code{yylloc}. For example, if you use @samp{%name-prefix="c_"}, the
|
||||
names become @code{c_parse}, @code{c_lex}, and so on. @xref{Multiple
|
||||
Parsers, ,Multiple Parsers in the Same Program}.
|
||||
|
||||
@item %no-parser
|
||||
Do not include any C code in the parser file; generate tables only. The
|
||||
|
||||
Reference in New Issue
Block a user