mirror of
https://git.savannah.gnu.org/git/bison.git
synced 2026-03-09 20:33:03 +00:00
glr2.cc: kill trailing white spaces
Fixes several calc tests.
Tests 566 568 570 657 still fail because of a name clash when using
%parse-param:
calc.cc:1395:85: error: declaration shadows a field of 'calc::parser' [-Werror,-Wshadow]
void glr_state::destroy (char const* yymsg, calc::parser& yyparser, semantic_value *result, int *count, int *nerrs)
^
calc.hh:441:21: note: previous declaration is here
semantic_value *result;
^
* data/skeletons/glr2.cc: Fix indentation/trailing spaces.
This commit is contained in:
@@ -1005,7 +1005,7 @@ namespace ]b4_namespace_ref[
|
|||||||
/** Source location for this state. */
|
/** Source location for this state. */
|
||||||
location_type yyloc;]])[
|
location_type yyloc;]])[
|
||||||
|
|
||||||
]b4_parse_assert_if([[
|
]b4_parse_assert_if([[
|
||||||
public:
|
public:
|
||||||
// Check invariants.
|
// Check invariants.
|
||||||
void check_ () const
|
void check_ () const
|
||||||
@@ -2088,10 +2088,10 @@ namespace ]b4_namespace_ref[
|
|||||||
class ]b4_parser_class[::glr_stack
|
class ]b4_parser_class[::glr_stack
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
]b4_parse_error_bmatch([custom\|detailed\|verbose], [[
|
]b4_parse_error_bmatch([custom\|detailed\|verbose], [[
|
||||||
// Needs access to yypact_value_is_default, etc.
|
// Needs access to yypact_value_is_default, etc.
|
||||||
friend context;
|
friend context;
|
||||||
]])[
|
]])[
|
||||||
|
|
||||||
glr_stack (size_t yysize, parser_type& yyparser_yyarg]m4_ifset([b4_parse_param], [, b4_parse_param_decl])[)
|
glr_stack (size_t yysize, parser_type& yyparser_yyarg]m4_ifset([b4_parse_param], [, b4_parse_param_decl])[)
|
||||||
: yyerrState (0)
|
: yyerrState (0)
|
||||||
@@ -2110,7 +2110,7 @@ namespace ]b4_namespace_ref[
|
|||||||
}
|
}
|
||||||
|
|
||||||
int yyerrState;
|
int yyerrState;
|
||||||
]b4_locations_if([[ /* To compute the location of the error token. */
|
]b4_locations_if([[ /* To compute the location of the error token. */
|
||||||
glr_stack_item yyerror_range[3];]])[
|
glr_stack_item yyerror_range[3];]])[
|
||||||
state_stack yystateStack;
|
state_stack yystateStack;
|
||||||
int yyerrcnt;
|
int yyerrcnt;
|
||||||
@@ -2143,11 +2143,11 @@ namespace ]b4_namespace_ref[
|
|||||||
YYCDEBUG << "Starting parse\n";
|
YYCDEBUG << "Starting parse\n";
|
||||||
|
|
||||||
this->yyla.clear ();
|
this->yyla.clear ();
|
||||||
]m4_ifdef([b4_initial_action], [
|
]m4_ifdef([b4_initial_action], [
|
||||||
b4_dollar_pushdef([yyla.value], [], [], [yyla.location])dnl
|
b4_dollar_pushdef([yyla.value], [], [], [yyla.location])dnl
|
||||||
b4_user_initial_action
|
b4_user_initial_action
|
||||||
b4_dollar_popdef])[]dnl
|
b4_dollar_popdef])[]dnl
|
||||||
[
|
[
|
||||||
switch (YYSETJMP (this->yyexception_buffer))
|
switch (YYSETJMP (this->yyexception_buffer))
|
||||||
{
|
{
|
||||||
case 0: break;
|
case 0: break;
|
||||||
@@ -2271,7 +2271,7 @@ namespace ]b4_namespace_ref[
|
|||||||
YYCDEBUG << "Stack " << yys.get() << " now in state "
|
YYCDEBUG << "Stack " << yys.get() << " now in state "
|
||||||
<< this->topState(yys)->yylrState << '\n';
|
<< this->topState(yys)->yylrState << '\n';
|
||||||
}
|
}
|
||||||
]b4_variant_if([[
|
]b4_variant_if([[
|
||||||
// FIXME: User destructors.
|
// FIXME: User destructors.
|
||||||
// Value type destructor.
|
// Value type destructor.
|
||||||
]b4_symbol_variant([[yytoken_to_shift]], [[this->yyla.value]], [[template destroy]])])[
|
]b4_symbol_variant([[yytoken_to_shift]], [[this->yyla.value]], [[template destroy]])])[
|
||||||
@@ -2372,14 +2372,14 @@ namespace ]b4_namespace_ref[
|
|||||||
{
|
{
|
||||||
if (yyerrState != 0)
|
if (yyerrState != 0)
|
||||||
return;
|
return;
|
||||||
]b4_parse_error_case(
|
]b4_parse_error_case(
|
||||||
[simple], [[
|
[simple], [[
|
||||||
std::string msg = YY_("syntax error");
|
std::string msg = YY_("syntax error");
|
||||||
yyparser.error (]b4_join(b4_locations_if([yyla.location]), [[YY_MOVE (msg)]])[);]],
|
yyparser.error (]b4_join(b4_locations_if([yyla.location]), [[YY_MOVE (msg)]])[);]],
|
||||||
[custom], [[
|
[custom], [[
|
||||||
context yyctx (*this, yyla);
|
context yyctx (*this, yyla);
|
||||||
yyparser.report_syntax_error (yyctx);]],
|
yyparser.report_syntax_error (yyctx);]],
|
||||||
[[
|
[[
|
||||||
context yyctx (*this, yyla);
|
context yyctx (*this, yyla);
|
||||||
std::string msg = yyparser.yysyntax_error_ (yyctx);
|
std::string msg = yyparser.yysyntax_error_ (yyctx);
|
||||||
yyparser.error (]b4_join(b4_locations_if([yyla.location]), [[YY_MOVE (msg)]])[);]])[
|
yyparser.error (]b4_join(b4_locations_if([yyla.location]), [[YY_MOVE (msg)]])[);]])[
|
||||||
@@ -3219,12 +3219,11 @@ namespace ]b4_namespace_ref[
|
|||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
]b4_parse_param_vars[
|
]b4_parse_param_vars[
|
||||||
}; // class ]b4_parser_class[::glr_stack
|
}; // class ]b4_parser_class[::glr_stack
|
||||||
} // namespace ]b4_namespace_ref[
|
} // namespace ]b4_namespace_ref[
|
||||||
|
|
||||||
|
|
||||||
/* DEBUGGING ONLY */
|
|
||||||
#if ]b4_api_PREFIX[DEBUG
|
#if ]b4_api_PREFIX[DEBUG
|
||||||
namespace
|
namespace
|
||||||
{
|
{
|
||||||
|
|||||||
Reference in New Issue
Block a user