summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--data/skeletons/lalr1.d2
-rw-r--r--tests/input.at7
-rw-r--r--tests/local.at9
-rw-r--r--tests/scanner.at2
4 files changed, 15 insertions, 5 deletions
diff --git a/data/skeletons/lalr1.d b/data/skeletons/lalr1.d
index df03dee8..dc54c664 100644
--- a/data/skeletons/lalr1.d
+++ b/data/skeletons/lalr1.d
@@ -17,6 +17,8 @@
m4_include(b4_skeletonsdir/[d.m4])
+b4_header_if([b4_complain([%header/%defines does not make sense in D])])
+
# parse.lac
b4_percent_define_default([[parse.lac]], [[none]])
b4_percent_define_check_values([[[[parse.lac]], [[full]], [[none]]]])
diff --git a/tests/input.at b/tests/input.at
index f41c3657..632be1a3 100644
--- a/tests/input.at
+++ b/tests/input.at
@@ -2682,7 +2682,7 @@ start: %empty;
# Only "full" and "none" are accepted for parse.lac
# Unknown values (such as "unsupported") are rejected
-m4_foreach([b4_skel], [[yacc.c], [lalr1.cc], [lalr1.java]],
+m4_foreach([b4_skel], [[yacc.c], [lalr1.cc], [lalr1.d], [lalr1.java]],
[AT_BISON_CHECK([[-S]b4_skel[ -Dparse.lac=none input.y]])
AT_BISON_CHECK([[-S]b4_skel[ -Dparse.lac=full input.y]])
AT_BISON_CHECK([[-S]b4_skel[ -Dparse.lac=unsupported input.y]],
@@ -2926,9 +2926,8 @@ exp:
# Disable -Wother to avoid the warnings about the suspicious presence
# of `b4_canary` in the output.
-m4_foreach([b4_skel],
- [[yacc.c], [glr.c], [lalr1.cc], [glr.cc], [glr2.cc], [lalr1.d], [lalr1.java]],
-[AT_BISON_CHECK([[-Wno-other -S ]b4_skel[ ]m4_bmatch(b4_skel, [.*\.java$], [], [-d])[ input.y]])
+AT_FOR_EACH_SKEL(
+[AT_BISON_CHECK([[-Wno-other -S ]b4_skel[ ]m4_bmatch(b4_skel, [.*\.\(d\|java\)$], [], [-d])[ input.y]])
])
])
diff --git a/tests/local.at b/tests/local.at
index 5dde77c2..e24c419d 100644
--- a/tests/local.at
+++ b/tests/local.at
@@ -157,6 +157,15 @@ m4_define([AT_SAVE_SPECIAL_FILES], [at_save_special_files])
m4_define([AT_RESTORE_SPECIAL_FILES], [at_restore_special_files])
+# AT_FOR_EACH_SKEL(BODY)
+# ----------------------
+m4_define([AT_FOR_EACH_SKEL],
+[m4_foreach([b4_skel],
+ [[yacc.c], [glr.c], [lalr1.cc], [glr.cc], [glr2.cc], [lalr1.d], [lalr1.java]],
+ [$1])
+])
+
+
## ------------------------------- ##
## Macros decoding Bison options. ##
diff --git a/tests/scanner.at b/tests/scanner.at
index 852e7c9a..44bae6e8 100644
--- a/tests/scanner.at
+++ b/tests/scanner.at
@@ -323,7 +323,7 @@ AT_BISON_OPTION_POPDEFS
AT_CLEANUP
])
-m4_foreach([b4_skel], [[yacc.c], [glr.c], [lalr1.cc], [glr.cc], [glr2.cc], [lalr1.java], [lalr1.d]],
+AT_FOR_EACH_SKEL(
[AT_TEST([%skeleton "]b4_skel["])
AT_TEST([%skeleton "]b4_skel[" %define api.token.raw])])