[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[PATCH 8/8] build: pacify syntax-check
From: |
Akim Demaille |
Subject: |
[PATCH 8/8] build: pacify syntax-check |
Date: |
Mon, 10 Feb 2020 20:49:16 +0100 |
* src/complain.c: Fix indentation.
* cfg.mk: Using strcmp is ok in the tests.
Test cases and examples don't need Bison's PO support.
---
cfg.mk | 4 ++--
src/complain.c | 4 ++--
2 files changed, 4 insertions(+), 4 deletions(-)
diff --git a/cfg.mk b/cfg.mk
index 0e5716cf..8b22f03b 100644
--- a/cfg.mk
+++ b/cfg.mk
@@ -156,7 +156,7 @@ exclude = \
$(call exclude,
\
bindtextdomain=^lib/main.c$$
\
cast_of_argument_to_free=^src/muscle-tab.c$$
\
- po_check=(^po/POTFILES.in|.md)$$
\
+ po_check=^(examples|tests)/|(^po/POTFILES.in|.md)$$
\
preprocessor_indentation=^data/|^lib/|^src/parse-gram.[ch]$$
\
program_name=^lib/main.c$$
\
prohibit_always-defined_macros=^data/skeletons/yacc.c$$
\
@@ -165,7 +165,7 @@ $(call exclude,
prohibit_doubled_word=^tests/named-refs.at$$
\
prohibit_magic_number_exit=^doc/bison.texi$$
\
prohibit_magic_number_exit+=?|^tests/(conflicts|regression).at$$
\
- prohibit_strcmp=^doc/bison\.texi|examples|tests/local\.at$$
\
+ prohibit_strcmp=^doc/bison\.texi|examples|tests
\
prohibit_tab_based_indentation=install-icc.sh|\.(am|mk)$$|^\.git|tests/input.at|Makefile$$
\
require_config_h=^(lib/yyerror|data/skeletons/(glr|yacc))\.c$$
\
require_config_h_first=^(lib/yyerror|data/skeletons/(glr|yacc))\.c$$
\
diff --git a/src/complain.c b/src/complain.c
index b8ba420e..dbf243e7 100644
--- a/src/complain.c
+++ b/src/complain.c
@@ -604,7 +604,7 @@ syntax_error (location loc,
const char *format = NULL;
switch (argc)
{
-# define CASE(N, S) \
+#define CASE(N, S) \
case N: \
format = S; \
break
@@ -615,7 +615,7 @@ syntax_error (location loc,
CASE (3, _("expected %1$s or %2$s before %0$s"));
CASE (4, _("expected %1$s or %2$s or %3$s before %0$s"));
CASE (5, _("expected %1$s or %2$s or %4$s or %5$s before %0$s"));
-# undef CASE
+#undef CASE
}
location_print (loc, stderr);
fputs (": ", stderr);
--
2.25.0
- [PATCH 0/8] Various updates, Akim Demaille, 2020/02/10
- [PATCH 1/8] doc: work around problems with PDF generation, Akim Demaille, 2020/02/10
- [PATCH 2/8] doc: formatting changes, Akim Demaille, 2020/02/10
- [PATCH 4/8] parse.error: document and diagnose the incompatibility with %token-table, Akim Demaille, 2020/02/10
- [PATCH 3/8] doc: spell check, Akim Demaille, 2020/02/10
- [PATCH 6/8] gnulib: update, Akim Demaille, 2020/02/10
- [PATCH 7/8] regen, Akim Demaille, 2020/02/10
- [PATCH 5/8] build: prefer %D% and %C% to hard coded values, Akim Demaille, 2020/02/10
- [PATCH 8/8] build: pacify syntax-check,
Akim Demaille <=