aboutsummaryrefslogtreecommitdiff
path: root/src/grecs-gram.y
diff options
context:
space:
mode:
Diffstat (limited to 'src/grecs-gram.y')
-rw-r--r--src/grecs-gram.y7
1 files changed, 5 insertions, 2 deletions
diff --git a/src/grecs-gram.y b/src/grecs-gram.y
index b72b52c..ad36795 100644
--- a/src/grecs-gram.y
+++ b/src/grecs-gram.y
@@ -1,6 +1,6 @@
%{
/* grecs - Gray's Extensible Configuration System
- Copyright (C) 2007-2021 Sergey Poznyakoff
+ Copyright (C) 2007-2022 Sergey Poznyakoff
Grecs is free software; you can redistribute it and/or modify it
under the terms of the GNU General Public License as published by the
@@ -241,10 +241,13 @@ opt_sc : /* empty */
%%
+int grecs_yyerror_suppress;
+
int
yyerror(char const *s)
{
- grecs_error(&yylloc, 0, "%s", s);
+ if (!grecs_yyerror_suppress)
+ grecs_error(&yylloc, 0, "%s", s);
return 0;
}

Return to:

Send suggestions and report system problems to the System administrator.