]> git.saurik.com Git - bison.git/commit - NEWS
warnings: used but undeclared symbols are warnings
authorVictor Santet <victor.santet@epita.fr>
Tue, 19 Jun 2012 14:14:55 +0000 (16:14 +0200)
committerAkim Demaille <akim@lrde.epita.fr>
Wed, 20 Jun 2012 08:30:26 +0000 (10:30 +0200)
commitb921d92fcbdb2c19fe2c6158e9a5181d451b976a
tree472f764fe75cb2a1f0dc10cdecba2f8081e45e0c
parentdda2c1adbab70a9e7ecaf3f83b3419fbd20fb321
warnings: used but undeclared symbols are warnings

We used to raise an error if a symbol appears only in a %printer or
%destructor.  Make it a warning.

* src/symtab.h (status): New enum.
(symbol): Replace the binary "declared" with the three-state "status".
Adjust dependencies.
* src/symtab.c (symbol_check_defined): Needed symbols are an error,
whereas "used" are simply warnings.
* src/symlist.c (symbol_list_destructor_set, symbol_list_printer): Set
symbol status to 'used' when associated to destructors or printers.
* input.at (Undeclared symbols used for a printer or destructor): New.
NEWS
src/reader.c
src/symlist.c
src/symtab.c
src/symtab.h
tests/input.at