]> git.saurik.com Git - bison.git/commit
Instead of mapping the LHS of unused rules to -1, keep the LHS
authorAkim Demaille <akim@epita.fr>
Fri, 30 Nov 2001 10:46:08 +0000 (10:46 +0000)
committerAkim Demaille <akim@epita.fr>
Fri, 30 Nov 2001 10:46:08 +0000 (10:46 +0000)
commitd39a6b7ca9c0ead60f4dd4bcf237597d40f846d3
treef75494c191877f2cc4a71ac53f92984e6be52a85
parentd287d66a69966117aa8dc1b2d00507ee98e528ab
Instead of mapping the LHS of unused rules to -1, keep the LHS
valid, but flag the rules as invalid.
* src/gram.h (rule_t): `useful' is a new member.
* src/print.c (print_grammar): Adjust.
* src/derives.c (set_derives): Likewise.
* src/reader.c (packgram, reduce_output): Likewise.
* src/reduce.c (reduce_grammar_tables): Likewise.
* tests/reduce.at (Underivable Rules, Useless Rules): New.
ChangeLog
src/derives.c
src/gram.h
src/print.c
src/reader.c
src/reduce.c
tests/reduce.at