mirror of
https://git.savannah.gnu.org/git/bison.git
synced 2026-03-21 10:13:03 +00:00
(yydoAction): Return YYRESULTTAG, not int.
(yyglrReduce): Return yyok, not 0. This should avoid the enumerated-type warnings reported by Nelson H. F. Beebe in <http://mail.gnu.org/pipermail/bug-bison/2002-November/001872.html>.
This commit is contained in:
@@ -1022,7 +1022,7 @@ yyglrShiftDefer (yyGLRStack* yystack, int yyk, yyStateNum yylrState,
|
|||||||
* have been previously resolved. Set *VALP to the resulting value,
|
* have been previously resolved. Set *VALP to the resulting value,
|
||||||
* and *LOCP to the computed location (if any). Return value is as
|
* and *LOCP to the computed location (if any). Return value is as
|
||||||
* for userAction. */
|
* for userAction. */
|
||||||
static inline int
|
static inline YYRESULTTAG
|
||||||
yydoAction (yyGLRStack* yystack, int yyk, yyRuleNum yyrule,
|
yydoAction (yyGLRStack* yystack, int yyk, yyRuleNum yyrule,
|
||||||
YYSTYPE* yyvalp, YYLTYPE* yylocp]b4_user_formals[)
|
YYSTYPE* yyvalp, YYLTYPE* yylocp]b4_user_formals[)
|
||||||
{
|
{
|
||||||
@@ -1168,7 +1168,7 @@ yyglrReduce (yyGLRStack* yystack, size_t yyk, yyRuleNum yyrule,
|
|||||||
yymarkStackDeleted (yystack, yyk);
|
yymarkStackDeleted (yystack, yyk);
|
||||||
YYDPRINTF ((stderr, "Merging stack %d into stack %d.\n",
|
YYDPRINTF ((stderr, "Merging stack %d into stack %d.\n",
|
||||||
yyk, yyi));
|
yyk, yyi));
|
||||||
return 0;
|
return yyok;
|
||||||
}
|
}
|
||||||
yyp = yyp->yypred;
|
yyp = yyp->yypred;
|
||||||
}
|
}
|
||||||
@@ -1176,7 +1176,7 @@ yyglrReduce (yyGLRStack* yystack, size_t yyk, yyRuleNum yyrule,
|
|||||||
yystack->yytops.yystates[yyk] = yys;
|
yystack->yytops.yystates[yyk] = yys;
|
||||||
yyglrShiftDefer (yystack, yyk, yynewLRState, yyposn, yys0, yyrule]b4_pure_args[);
|
yyglrShiftDefer (yystack, yyk, yynewLRState, yyposn, yys0, yyrule]b4_pure_args[);
|
||||||
}
|
}
|
||||||
return 0;
|
return yyok;
|
||||||
}
|
}
|
||||||
|
|
||||||
static int
|
static int
|
||||||
|
|||||||
Reference in New Issue
Block a user