c++: fix a few style issues

* data/skeletons/lalr1.cc (yystack_print_, yy_reduce_print_): Add
missing const.
(yystack_print_): Rename as...
(yy_stack_print_): this.
* data/skeletons/glr.cc (yy_symbol_value_print_, yy_symbol_print_):
Add missing const.
This commit is contained in:
Akim Demaille
2020-04-26 08:01:33 +02:00
parent 286d0755f8
commit cbbbe12e02
2 changed files with 10 additions and 10 deletions

View File

@@ -167,7 +167,7 @@ m4_pushdef([b4_parse_param], m4_defn([b4_parse_param_orig]))dnl
void
]b4_parser_class[::yy_symbol_value_print_ (symbol_kind_type yykind,
const semantic_type* yyvaluep]b4_locations_if([[,
const location_type* yylocationp]])[)
const location_type* yylocationp]])[) const
{]b4_locations_if([[
YYUSE (yylocationp);]])[
YYUSE (yyvaluep);
@@ -181,7 +181,7 @@ m4_pushdef([b4_parse_param], m4_defn([b4_parse_param_orig]))dnl
void
]b4_parser_class[::yy_symbol_print_ (symbol_kind_type yykind,
const semantic_type* yyvaluep]b4_locations_if([[,
const location_type* yylocationp]])[)
const location_type* yylocationp]])[) const
{
*yycdebug_ << (yykind < YYNTOKENS ? "token" : "nterm")
<< ' ' << yytname[yykind] << " ("]b4_locations_if([[
@@ -317,16 +317,16 @@ b4_percent_code_get([[requires]])[
/// \param yylocationp Its location.]])[
virtual void yy_symbol_value_print_ (symbol_kind_type yykind,
const semantic_type* yyvaluep]b4_locations_if([[,
const location_type* yylocationp]])[);
const location_type* yylocationp]])[) const;
/// \brief Report a symbol on the debug stream.
/// \param yykind The symbol kind.
/// \param yyvaluep Its semantic value.]b4_locations_if([[
/// \param yylocationp Its location.]])[
virtual void yy_symbol_print_ (symbol_kind_type yykind,
const semantic_type* yyvaluep]b4_locations_if([[,
const location_type* yylocationp]])[);
const location_type* yylocationp]])[) const;
private:
// Debugging.
/// Debug stream.
std::ostream* yycdebug_;
#endif