mirror of
https://git.savannah.gnu.org/git/bison.git
synced 2026-03-09 12:23:04 +00:00
java: use the same calc tests as the other skeletons
* tests/local.at (AT_LANG_MATCH): New. (AT_YYERROR_DECLARE(java), AT_YYERROR_DECLARE_EXTERN(java)): New. * tests/calc.at: The grammar file for Java is quite different for the others, and continuing to assemble it from pieces makes the grammar file hard to understand. Let's also dispatch on the language to assemble it, and isolate Java from the others. Most of this comes from java.at.
This commit is contained in:
@@ -442,6 +442,12 @@ m4_define([AT_LANG_CASE],
|
||||
[m4_case(AT_LANG, $@)])
|
||||
|
||||
|
||||
# AT_LANG_MATCH(LANG1, IF-LANG1, LANG2, IF-LANG2, ..., DEFAULT)
|
||||
# ------------------------------------------------------------
|
||||
m4_define([AT_LANG_MATCH],
|
||||
[m4_bmatch(AT_LANG, $@)])
|
||||
|
||||
|
||||
# _AT_LANG_DISPATCH(LANG, MACRO, ARGS)
|
||||
# ------------------------------------
|
||||
# Call the specialization of MACRO for LANG with ARGS. Complain if
|
||||
@@ -818,6 +824,9 @@ m4_define([AT_MAIN_DEFINE(d)],
|
||||
# ------------------------------
|
||||
m4_copy([AT_DATA], [AT_DATA_GRAMMAR(java)])
|
||||
|
||||
# No need to declare, it's part of the class interface.
|
||||
m4_define([AT_YYERROR_DECLARE(java)], [])
|
||||
m4_define([AT_YYERROR_DECLARE_EXTERN(java)], [])
|
||||
|
||||
# AT_JAVA_POSITION_DEFINE
|
||||
# -----------------------
|
||||
|
||||
Reference in New Issue
Block a user