d: change name of YYParser.Symbol's semanticValue() to value()

Member value was renamed to value_ to avoid the name clash.

* data/skeletons/d.m4: Change member names.
* data/skeletons/lalr1.d: Adjust.
This commit is contained in:
Adela Vais
2020-12-10 22:36:24 +02:00
committed by Akim Demaille
parent c6a39f8409
commit 848a17fa33
2 changed files with 4 additions and 4 deletions

View File

@@ -460,7 +460,7 @@ m4_define([b4_symbol_type_define],
struct Symbol
{
private SymbolKind kind;
private ]b4_yystype[ value;]b4_locations_if([[
private ]b4_yystype[ value_;]b4_locations_if([[
private YYLocation location_;]])[
this(TokenKind token]b4_locations_if([[, YYLocation loc]])[)
{
@@ -472,12 +472,12 @@ m4_define([b4_symbol_type_define],
this(TokenKind token, typeof(mixin("YYSemanticType." ~ member)) val]b4_locations_if([[, YYLocation loc]])[)
{
kind = yytranslate_(token);
mixin("value." ~ member ~ " = val;");]b4_locations_if([
mixin("value_." ~ member ~ " = val;");]b4_locations_if([
location_ = loc;])[
}
}
SymbolKind token() { return kind; }
]b4_yystype[ semanticValue() { return value; }]b4_locations_if([[
]b4_yystype[ value() { return value_; }]b4_locations_if([[
YYLocation location() { return location_; }]])[
}
]])

View File

@@ -493,7 +493,7 @@ m4_popdef([b4_at_dollar])])dnl
yycdebugln ("Reading a token");]])[
Symbol yysymbol = yylex();
yychar = yysymbol.token();
yylval = yysymbol.semanticValue();]b4_locations_if([[
yylval = yysymbol.value();]b4_locations_if([[
yylloc = yysymbol.location();]])[
}