mirror of
https://git.savannah.gnu.org/git/bison.git
synced 2026-03-19 01:03:04 +00:00
tests: check that parse-gram.y's IELR and LALR are identical.
* tests/atlocal.in (abs_top_srcdir): New shell variable. * tests/regression.at (parse-gram.y: LALR = IELR): New test group.
This commit is contained in:
@@ -1,3 +1,10 @@
|
|||||||
|
2009-09-26 Joel E. Denny <jdenny@clemson.edu>
|
||||||
|
|
||||||
|
tests: check that parse-gram.y's IELR and LALR are identical.
|
||||||
|
* tests/atlocal.in (abs_top_srcdir): New shell variable.
|
||||||
|
* tests/regression.at (parse-gram.y: LALR = IELR): New test
|
||||||
|
group.
|
||||||
|
|
||||||
2009-09-19 Alex Rozenman <rozenman@gmail.com>
|
2009-09-19 Alex Rozenman <rozenman@gmail.com>
|
||||||
|
|
||||||
Keep sub-messages aligned. Fix strings for translation.
|
Keep sub-messages aligned. Fix strings for translation.
|
||||||
|
|||||||
@@ -42,3 +42,5 @@ CONF_JAVA='@CONF_JAVA@'
|
|||||||
|
|
||||||
# We need egrep.
|
# We need egrep.
|
||||||
: ${EGREP='@EGREP@'}
|
: ${EGREP='@EGREP@'}
|
||||||
|
|
||||||
|
abs_top_srcdir='@abs_top_srcdir@'
|
||||||
|
|||||||
@@ -1237,3 +1237,24 @@ AT_COMPILE([[input]])
|
|||||||
AT_PARSER_CHECK([[./input]])
|
AT_PARSER_CHECK([[./input]])
|
||||||
|
|
||||||
AT_CLEANUP
|
AT_CLEANUP
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
## --------------------------- ##
|
||||||
|
## parse-gram.y: LALR = IELR. ##
|
||||||
|
## --------------------------- ##
|
||||||
|
|
||||||
|
# If parse-gram.y's LALR and IELR parser tables ever begin to differ, we
|
||||||
|
# need to fix parse-gram.y or start using IELR.
|
||||||
|
|
||||||
|
AT_SETUP([[parse-gram.y: LALR = IELR]])
|
||||||
|
|
||||||
|
# Avoid tests/bison's dark magic by processing a local copy of the
|
||||||
|
# grammar. Avoid differences in synclines by telling bison that the
|
||||||
|
# output files have the same name.
|
||||||
|
cp $abs_top_srcdir/src/parse-gram.y input.y
|
||||||
|
AT_BISON_CHECK([[-o input.c -Dlr.type=lalr input.y && mv input.c lalr.c]])
|
||||||
|
AT_BISON_CHECK([[-o input.c -Dlr.type=ielr input.y && mv input.c ielr.c]])
|
||||||
|
AT_CHECK([[diff -u lalr.c ielr.c]])
|
||||||
|
|
||||||
|
AT_CLEANUP
|
||||||
|
|||||||
Reference in New Issue
Block a user