summaryrefslogtreecommitdiff
path: root/examples
diff options
context:
space:
mode:
authorAkim Demaille <akim.demaille@gmail.com>2020-04-28 07:28:52 +0200
committerAkim Demaille <akim.demaille@gmail.com>2020-04-28 07:54:07 +0200
commitcd4e799da482d0fdfc2305ff66a9ea43cea5ad7b (patch)
tree7e2ff0804c431beef467cb1626b8f95302bef5a2 /examples
parent7346163840080f289f0adbadfbf5659c620d5fea (diff)
downloadbison-cd4e799da482d0fdfc2305ff66a9ea43cea5ad7b.tar.gz
error: rename the error token from YYERRCODE to YYerror
See https://lists.gnu.org/r/bison-patches/2020-04/msg00162.html. * data/skeletons/bison.m4, data/skeletons/c.m4, data/skeletons/glr.cc, * data/skeletons/lalr1.java, doc/bison.texi, * examples/c/bistromathic/parse.y, src/scan-gram.l, src/symtab.c (YYERRCODE): Rename as... (YYerror): this. Adjust dependencies.
Diffstat (limited to 'examples')
-rwxr-xr-xexamples/c/bistromathic/bistromathic.test2
-rw-r--r--examples/c/bistromathic/parse.y2
2 files changed, 2 insertions, 2 deletions
diff --git a/examples/c/bistromathic/bistromathic.test b/examples/c/bistromathic/bistromathic.test
index 9a5b6d11..1e5bd0e1 100755
--- a/examples/c/bistromathic/bistromathic.test
+++ b/examples/c/bistromathic/bistromathic.test
@@ -118,7 +118,7 @@ run 0 '> 100% + 10
err: 1.4: syntax error: invalid character: %'
# Traces. This allows to check the location of the error. If we
-# forget to map YYERRCODE to YYUNDEF, error recovery enters an endless
+# forget to map YYerror to YYUNDEF, error recovery enters an endless
# loop with this input.
cat >input <<EOF
(+_)
diff --git a/examples/c/bistromathic/parse.y b/examples/c/bistromathic/parse.y
index 042c5616..925e06f5 100644
--- a/examples/c/bistromathic/parse.y
+++ b/examples/c/bistromathic/parse.y
@@ -300,7 +300,7 @@ yylex (const char **line, YYSTYPE *yylval, YYLTYPE *yylloc)
// Stray characters.
default:
yyerror (yylloc, "syntax error: invalid character: %c", c);
- return TOK_YYERRCODE;
+ return TOK_YYerror;
}
}