style: c++: formatting changes

Akim Demaille <[email protected]> Thu, 2 Sep 2021 07:13:54 +0200
Newsgroups gmane.comp.parsers.bison.patches
Message-ID <[email protected]>
commit 075a87905210c50058f38debf045f665720ece93
Author: Akim Demaille <[email protected]>
Date:   Sun Aug 29 16:39:27 2021 +0200

    style: c++: formatting changes
   =20
    * data/skeletons/variant.hh, data/skeletons/glr2.cc: Fix space =
before
    paren issue.

diff --git a/data/skeletons/glr2.cc b/data/skeletons/glr2.cc
index d682a078..4a0a8f9e 100644
--- a/data/skeletons/glr2.cc
+++ b/data/skeletons/glr2.cc
@@ -2162,7 +2162,7 @@ b4_dollar_popdef])[]dnl
                reductions on all stacks) helps prevent double =
destructor calls
                on yylval in the event of memory exhaustion.  */
=20
-            for (state_set_index yys =3D create_state_set_index(0); =
yys.uget() < this->yystateStack.numTops(); ++yys)
+            for (state_set_index yys =3D create_state_set_index (0); =
yys.uget () < this->yystateStack.numTops (); ++yys)
               YYCHK1 (this->yyprocessOneStack (yys, =
yyposn]b4_locations_if([, &this->yylloc])[));
             this->yystateStack.yytops.yyremoveDeletes ();
             if (this->yystateStack.yytops.size() =3D=3D 0)
@@ -2172,7 +2172,7 @@ b4_dollar_popdef])[]dnl
                   this->yyFail (]b4_locations_if([&this->yylloc, =
])[YY_("syntax error"));
                 YYCHK1 (this->yyresolveStack ());
                 YYCDEBUG << "Returning to deterministic =
operation.\n";]b4_locations_if([[
-                this->yyerror_range[1].getState().yyloc =3D =
this->yylloc;]])[
+                this->yyerror_range[1].getState ().yyloc =3D =
this->yylloc;]])[
                 this->yyreportSyntaxError ();
                 goto yyuser_error;
               }
@@ -2185,12 +2185,11 @@ b4_dollar_popdef])[]dnl
             yysymbol_kind_t yytoken_to_shift =3D this->yytoken;
             this->yytoken =3D ]b4_symbol(empty, kind)[;
             yyposn +=3D 1;
-            for (state_set_index yys =3D create_state_set_index(0); =
yys.uget() < this->yystateStack.numTops(); ++yys)
+            for (state_set_index yys =3D create_state_set_index (0); =
yys.uget () < this->yystateStack.numTops (); ++yys)
               {
-                const state_num yystate =3D =
this->topState(yys)->yylrState;
+                const state_num yystate =3D this->topState =
(yys)->yylrState;
                 const short* yyconflicts;
-                const int yyaction
-                  =3D yygetLRActions (yystate, yytoken_to_shift, =
yyconflicts);
+                const int yyaction =3D yygetLRActions (yystate, =
yytoken_to_shift, yyconflicts);
                 /* Note that yyconflicts were handled by =
yyprocessOneStack.  */
                 YYCDEBUG << "On stack " << yys.get() << ", ";
                 YY_SYMBOL_PRINT ("shifting", yytoken_to_shift, =
this->yylval, this->yylloc);
@@ -2203,7 +2202,7 @@ b4_dollar_popdef])[]dnl
               // Value type destructor.
               ]b4_symbol_variant([[yytoken_to_shift]], =
[[this->yylval]], [[template destroy]])])[
=20
-            if (this->yystateStack.yytops.size() =3D=3D 1)
+            if (this->yystateStack.yytops.size () =3D=3D 1)
               {
                 YYCHK1 (this->yyresolveStack ());
                 YYCDEBUG << "Returning to deterministic operation.\n";
diff --git a/data/skeletons/variant.hh b/data/skeletons/variant.hh
index e7177d9f..b657080f 100644
--- a/data/skeletons/variant.hh
+++ b/data/skeletons/variant.hh
@@ -470,18 +470,18 @@ m4_define([_b4_symbol_constructor_define],
           b4_symbol_if([$1], [has_type],
                        [b4_symbol([$1], [type]) v]),
           b4_locations_if([location_type l]))[)
-        : super_type(]b4_join([token_type (tok)],
-                              b4_symbol_if([$1], [has_type], [std::move =
(v)]),
-                              b4_locations_if([std::move (l)]))[)
+        : super_type (]b4_join([token_type (tok)],
+                               b4_symbol_if([$1], [has_type], =
[std::move (v)]),
+                               b4_locations_if([std::move (l)]))[)
 #else
       symbol_type (]b4_join(
           [int tok],
           b4_symbol_if([$1], [has_type],
                        [const b4_symbol([$1], [type])& v]),
           b4_locations_if([const location_type& l]))[)
-        : super_type(]b4_join([token_type (tok)],
-                              b4_symbol_if([$1], [has_type], [v]),
-                              b4_locations_if([l]))[)
+        : super_type (]b4_join([token_type (tok)],
+                               b4_symbol_if([$1], [has_type], [v]),
+                               b4_locations_if([l]))[)
 #endif
       {]b4_parse_assert_if([[
 #if !defined _MSC_VER || defined __clang__