mirror of
https://git.savannah.gnu.org/git/bison.git
synced 2026-03-16 07:43:03 +00:00
%printer: support both yyo and yyoutput.
lalr1.cc used to support yyo, but not yyoutput. Support both, but document only yyoutput (at least until there is some consensus on this). * data/c.m4 (yy_symbol_value_print): Also support yyo. * data/glr.cc (yy_symbol_value_print_): Support both yyo and yyoutput. * data/lalr1.cc: Also support yyoutput. * doc/bison.texinfo: Explicitly use yyoutput in the examples. * examples/mfcalc/mfcalc.test: Test the -p option.
This commit is contained in:
@@ -148,9 +148,11 @@ m4_pushdef([b4_parse_param], m4_defn([b4_parse_param_orig]))dnl
|
||||
]b4_parser_class_name[::yy_symbol_value_print_ (int yytype,
|
||||
const semantic_type* yyvaluep, const location_type* yylocationp)
|
||||
{
|
||||
/* Pacify ``unused variable'' warnings. */
|
||||
YYUSE (yyvaluep);
|
||||
YYUSE (yylocationp);
|
||||
YYUSE (yyvaluep);
|
||||
std::ostream& yyoutput = debug_stream ();
|
||||
std::ostream& yyo = yyoutput;
|
||||
YYUSE (yyo);
|
||||
switch (yytype)
|
||||
{
|
||||
]b4_symbol_foreach([b4_symbol_printer])dnl
|
||||
|
||||
Reference in New Issue
Block a user