]> git.saurik.com Git - bison.git/commitdiff
maint: address sc_prohibit_always-defined_macros.
authorAkim Demaille <demaille@gostai.com>
Sun, 19 Feb 2012 10:40:36 +0000 (11:40 +0100)
committerAkim Demaille <demaille@gostai.com>
Sun, 19 Feb 2012 11:54:06 +0000 (12:54 +0100)
* cfg.mk: No longer skip it, except where EXIT_SUCCESS is used
as a witness for stdlib.h.
Skip this test when appropriate.
* data/yacc.c: Drop a note about why EXIT_SUCCESS is defined here.

cfg.mk
data/yacc.c

diff --git a/cfg.mk b/cfg.mk
index 503dda6af42c7d49e08068434a8d0cb2d25fc221..0c539cb6193b669683cfce26945f81f6c09408f4 100644 (file)
--- a/cfg.mk
+++ b/cfg.mk
@@ -35,7 +35,6 @@ url_dir_list = \
 # Tests not to run as part of "make distcheck".
 local-checks-to-skip =                 \
   sc_immutable_NEWS                    \
-  sc_prohibit_always-defined_macros    \
   sc_prohibit_always_true_header_tests \
   sc_prohibit_atoi_atof                        \
   sc_prohibit_doubled_word             \
@@ -56,11 +55,14 @@ update-copyright-env = \
   UPDATE_COPYRIGHT_FORCE=1 UPDATE_COPYRIGHT_USE_INTERVALS=1
 
 exclude = $(foreach a,$(1),$(eval exclude_file_name_regexp--sc_$(a)))
-$(call exclude,                                                        \
-  bindtextdomain=^lib/main.c$$                                 \
-  program_name=^lib/main.c$$                                   \
-  prohibit_empty_lines_at_EOF=^src/parse-gram.h$$              \
-  require_config_h_first=^(lib/yyerror|data/(glr|yacc))\.c$$   \
-  space_tab=^tests/(input|c\+\+)\.at$$                         \
-  unmarked_diagnostics=^djgpp/                                 \
+$(call exclude,                                                                \
+  bindtextdomain=^lib/main.c$$                                         \
+  program_name=^lib/main.c$$                                           \
+  prohibit_always-defined_macros=^data/yacc.c|^djgpp/                  \
+  prohibit_always-defined_macros+=?|^src/(parse-gram.c|system.h)$$     \
+  prohibit_always-defined_macros+=?|^tests/regression.at$$             \
+  prohibit_empty_lines_at_EOF=^src/parse-gram.h$$                      \
+  require_config_h_first=^(lib/yyerror|data/(glr|yacc))\.c$$           \
+  space_tab=^tests/(input|c\+\+)\.at$$                                 \
+  unmarked_diagnostics=^djgpp/                                         \
 )
index 5f4ddafbf727fa6664e5fa0f5405f367849b1588..d59caf34caf94b2106a3cc6d7c3017675913e2d7 100644 (file)
@@ -438,6 +438,7 @@ b4_push_if([], [b4_lac_if([], [[
 #    define YYSTACK_ALLOC alloca
 #    if ! defined _ALLOCA_H && ! defined EXIT_SUCCESS && ]b4_c_modern[
 #     include <stdlib.h> /* INFRINGES ON USER NAME SPACE */
+      /* Use EXIT_SUCCESS as a witness for stdlib.h.  */
 #     ifndef EXIT_SUCCESS
 #      define EXIT_SUCCESS 0
 #     endif