mirror of
https://git.savannah.gnu.org/git/bison.git
synced 2026-03-12 13:53:03 +00:00
warnings: sort the messages by location
Sort the warnings by location (file, line number, column). They are built using an obstack then stored in a list, and finally sorted just before being printed, at the end. * src/complain.c, src/complain.h: New warning struct, obstack, and implementation * src/location.c, location.h (location_obstack_caret, location_obstack_print): New * src/main.c: Print the warnings * src/muscle-tab.c, src/reader.c, src/scan-code.l, src/symtab.c: Adapt for multi-part warnings * tests/actions.at, tests/conflicts.at, tests/existing.at, tests/input.at, * tests/reduce.at, tests/regression.at, tests/skeleton.at: Update testsuite
This commit is contained in:
@@ -203,7 +203,6 @@ main (int argc, char *argv[])
|
||||
contains things such as user actions, prologue, epilogue etc. */
|
||||
gram_scanner_free ();
|
||||
muscle_free ();
|
||||
uniqstrs_free ();
|
||||
code_scanner_free ();
|
||||
skel_scanner_free ();
|
||||
quotearg_free ();
|
||||
@@ -218,6 +217,9 @@ main (int argc, char *argv[])
|
||||
timevar_stop (TV_TOTAL);
|
||||
timevar_print (stderr);
|
||||
|
||||
print_warnings (stderr);
|
||||
|
||||
uniqstrs_free ();
|
||||
cleanup_caret ();
|
||||
|
||||
return complaint_status ? EXIT_FAILURE : EXIT_SUCCESS;
|
||||
|
||||
Reference in New Issue
Block a user