c, c++: rename yysymbol_type_t as yysymbol_kind_t

See https://lists.gnu.org/r/bison-patches/2020-04/msg00031.html

* data/skeletons/c.m4, data/skeletons/glr.c, data/skeletons/yacc.c
(yysymbol_type_t): Rename as...
(yysymbol_kind_t): this.
Adjust dependencies.
* data/skeletons/c++.m4, data/skeletons/glr.cc, data/skeletons/lalr1.cc
(symbol_type_type): Rename as...
(symbol_kind_type): this.
Adjust dependencies.
This commit is contained in:
Akim Demaille
2020-04-05 11:06:21 +02:00
parent 57bc3c9013
commit 2c05fc750a
12 changed files with 115 additions and 115 deletions

View File

@@ -69,7 +69,7 @@ m4_defn([b4_parse_param]))],
# b4_declare_symbol_enum
# ----------------------
m4_append([b4_declare_symbol_enum],
[[typedef symbol_type_type yysymbol_type_t;
[[typedef symbol_kind_type yysymbol_kind_t;
]])
@@ -83,7 +83,7 @@ m4_define([b4_yy_symbol_print_define],
`--------------------*/
static void
yy_symbol_print (FILE *, ]b4_namespace_ref::b4_parser_class[::symbol_type_type yytype,
yy_symbol_print (FILE *, ]b4_namespace_ref::b4_parser_class[::symbol_kind_type yytype,
const ]b4_namespace_ref::b4_parser_class[::semantic_type *yyvaluep]b4_locations_if([[,
const ]b4_namespace_ref::b4_parser_class[::location_type *yylocationp]])[]b4_user_formals[)
{
@@ -175,7 +175,7 @@ m4_pushdef([b4_parse_param], m4_defn([b4_parse_param_orig]))dnl
`--------------------*/
void
]b4_parser_class[::yy_symbol_value_print_ (symbol_type_type yytype,
]b4_parser_class[::yy_symbol_value_print_ (symbol_kind_type yytype,
const semantic_type* yyvaluep]b4_locations_if([[,
const location_type* yylocationp]])[)
{]b4_locations_if([[
@@ -189,7 +189,7 @@ m4_pushdef([b4_parse_param], m4_defn([b4_parse_param_orig]))dnl
void
]b4_parser_class[::yy_symbol_print_ (symbol_type_type yytype,
]b4_parser_class[::yy_symbol_print_ (symbol_kind_type yytype,
const semantic_type* yyvaluep]b4_locations_if([[,
const location_type* yylocationp]])[)
{
@@ -325,14 +325,14 @@ b4_percent_code_get([[requires]])[
/// \param yytype The token type.
/// \param yyvaluep Its semantic value.]b4_locations_if([[
/// \param yylocationp Its location.]])[
virtual void yy_symbol_value_print_ (symbol_type_type yytype,
virtual void yy_symbol_value_print_ (symbol_kind_type yytype,
const semantic_type* yyvaluep]b4_locations_if([[,
const location_type* yylocationp]])[);
/// \brief Report a symbol on the debug stream.
/// \param yytype The token type.
/// \param yyvaluep Its semantic value.]b4_locations_if([[
/// \param yylocationp Its location.]])[
virtual void yy_symbol_print_ (symbol_type_type yytype,
virtual void yy_symbol_print_ (symbol_kind_type yytype,
const semantic_type* yyvaluep]b4_locations_if([[,
const location_type* yylocationp]])[);
private:
@@ -356,7 +356,7 @@ b4_percent_define_flag_if([[global_tokens_and_yystype]],
]b4_namespace_close[
]m4_define([b4_declare_symbol_enum],
[[typedef ]b4_namespace_ref[::]b4_parser_class[::symbol_type_type yysymbol_type_t;
[[typedef ]b4_namespace_ref[::]b4_parser_class[::symbol_kind_type yysymbol_kind_t;
#define YYSYMBOL_YYEMPTY ]b4_namespace_ref[::]b4_parser_class[::YYSYMBOL_YYEMPTY
#define YYSYMBOL_YYERROR ]b4_namespace_ref[::]b4_parser_class[::YYSYMBOL_YYERROR
#define YYSYMBOL_YYEOF ]b4_namespace_ref[::]b4_parser_class[::YYSYMBOL_YYEOF