mirror of
https://git.savannah.gnu.org/git/bison.git
synced 2026-03-11 05:13:04 +00:00
warnings: fix early exit of warnings treated as errors
Treating warnings as errors caused Bison to exit earlier than needed, making it hide warnings that would have been printed had -Werror not been set. Also, fix a bug that caused some context information of errors to not be shown. * src/complain.c (complaint_issued): Rename as... (complaint_status): This, and change its type from boolean to * src/complain.h (err_status): This, new enumeration. * src/main.c (main): Adjust (only finish early if an actual complaint was risen, not a mere warning treated an error). * src/reader.c: Adjust.
This commit is contained in:
@@ -631,7 +631,7 @@ reader (void)
|
||||
gram_parse ();
|
||||
prepare_percent_define_front_end_variables ();
|
||||
|
||||
if (! complaint_issued)
|
||||
if (complaint_status < status_complaint)
|
||||
check_and_convert_grammar ();
|
||||
|
||||
xfclose (gram_in);
|
||||
|
||||
Reference in New Issue
Block a user