From 2da399d15f8cc08ffaf196735802fa381a43566d Mon Sep 17 00:00:00 2001 From: Akim Demaille Date: Sat, 9 May 2020 17:02:32 +0200 Subject: [PATCH] yacc.c: restore ansi-c compatibility Reported by neok-m4700. https://github.com/akimd/bison/issues/37 * data/skeletons/yacc.c: Don't use // comments. --- data/skeletons/yacc.c | 2 +- src/parse-gram.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/data/skeletons/yacc.c b/data/skeletons/yacc.c index a790f6fa..a9f15c8d 100644 --- a/data/skeletons/yacc.c +++ b/data/skeletons/yacc.c @@ -1979,7 +1979,7 @@ yyerrorlab: yyerrlab1: yyerrstatus = 3; /* Each real token shifted decrements this. */ - // Pop stack until we find a state that shifts the error token. + /* Pop stack until we find a state that shifts the error token. */ for (;;) { yyn = yypact[yystate]; diff --git a/src/parse-gram.c b/src/parse-gram.c index a021e1aa..212e95d5 100644 --- a/src/parse-gram.c +++ b/src/parse-gram.c @@ -2705,7 +2705,7 @@ yyerrorlab: yyerrlab1: yyerrstatus = 3; /* Each real token shifted decrements this. */ - // Pop stack until we find a state that shifts the error token. + /* Pop stack until we find a state that shifts the error token. */ for (;;) { yyn = yypact[yystate];