COMP: update lemon to 2019-12-19 version

This commit is contained in:
Mark Olesen
2020-01-10 14:35:04 +01:00
parent 8fdb9b2f70
commit 9b67ffaf74
4 changed files with 152 additions and 57 deletions

View File

@ -347,8 +347,8 @@ void ParseInit(void *yypRawParser ParseCTX_PDECL){
#if YYSTACKDEPTH>0
yypParser->yystackEnd = &yypParser->yystack[YYSTACKDEPTH-1];
#endif
%namespace_end
}
%namespace_end
#ifndef Parse_ENGINEALWAYSONSTACK
/*
@ -739,12 +739,15 @@ static YYACTIONTYPE yy_reduce(
if( yyTraceFILE && yyruleno<(int)(sizeof(yyRuleName)/sizeof(yyRuleName[0])) ){
yysize = yyRuleInfoNRhs[yyruleno];
if( yysize ){
fprintf(yyTraceFILE, "%sReduce %d [%s], go to state %d.\n",
fprintf(yyTraceFILE, "%sReduce %d [%s]%s, pop back to state %d.\n",
yyTracePrompt,
yyruleno, yyRuleName[yyruleno], yymsp[yysize].stateno);
yyruleno, yyRuleName[yyruleno],
yyruleno<YYNRULE_WITH_ACTION ? "" : " without external action",
yymsp[yysize].stateno);
}else{
fprintf(yyTraceFILE, "%sReduce %d [%s].\n",
yyTracePrompt, yyruleno, yyRuleName[yyruleno]);
fprintf(yyTraceFILE, "%sReduce %d [%s]%s.\n",
yyTracePrompt, yyruleno, yyRuleName[yyruleno],
yyruleno<YYNRULE_WITH_ACTION ? "" : " without external action");
}
}
#endif /* NDEBUG */
@ -1085,7 +1088,7 @@ int ParseFallback(int iToken){
return yyFallback[iToken];
#else
(void)iToken;
#endif
return 0;
#endif
}
%namespace_end

View File

@ -1,5 +1,5 @@
--- lempar.c.orig 2019-08-30 17:49:01.815549795 +0200
+++ lempar.c 2019-09-26 16:09:17.880373536 +0200
--- lempar.c.orig 2020-01-10 14:08:55.225662130 +0100
+++ lempar.c 2020-01-10 14:31:25.891656998 +0100
@@ -251,12 +251,14 @@
** Outputs:
** None.
@ -23,14 +23,14 @@
void ParseInit(void *yypRawParser ParseCTX_PDECL){
yyParser *yypParser = (yyParser*)yypRawParser;
ParseCTX_STORE
@@ -344,6 +347,7 @@
#if YYSTACKDEPTH>0
@@ -345,6 +348,7 @@
yypParser->yystackEnd = &yypParser->yystack[YYSTACKDEPTH-1];
#endif
+%namespace_end
}
+%namespace_end
#ifndef Parse_ENGINEALWAYSONSTACK
/*
@@ -359,6 +363,7 @@
** A pointer to a parser. This pointer is used in subsequent calls
** to Parse and ParseFree.
@ -107,7 +107,7 @@
#endif
/*
@@ -893,6 +907,7 @@
@@ -891,6 +905,7 @@
** Outputs:
** None.
*/
@ -115,7 +115,7 @@
void Parse(
void *yyp, /* The parser */
int yymajor, /* The major token code number */
@@ -1062,11 +1077,13 @@
@@ -1060,11 +1075,13 @@
#endif
return;
}
@ -128,9 +128,9 @@
+%namespace_begin
int ParseFallback(int iToken){
#ifdef YYFALLBACK
if( iToken<(int)(sizeof(yyFallback)/sizeof(yyFallback[0])) ){
@@ -1077,3 +1094,4 @@
#endif
assert( iToken<(int)(sizeof(yyFallback)/sizeof(yyFallback[0])) );
@@ -1074,3 +1091,4 @@
return 0;
#endif
}
+%namespace_end