mirror of
https://git.savannah.gnu.org/git/bison.git
synced 2026-03-13 22:33:03 +00:00
errors: show carets
* src/locations.c (caret_info): New, persistant information useful for... (location_caret): New, print a caret. (cleanup_caret): Release caret_info cleanly, call it... * src/main.c (main): Here. * src/complain.c (error_message): Call location_caret here.
This commit is contained in:
@@ -102,6 +102,13 @@ void location_compute (location *loc,
|
||||
characters. */
|
||||
unsigned location_print (FILE *out, location loc);
|
||||
|
||||
/* Free any allocated ressources and close any open file handles that are
|
||||
left-over by the usage of location_caret. */
|
||||
void cleanup_caret (void);
|
||||
|
||||
/* Output to OUT the line and caret corresponding to location LOC. */
|
||||
void location_caret (FILE *out, location loc);
|
||||
|
||||
/* Return -1, 0, 1, depending whether a is before, equal, or
|
||||
after b. */
|
||||
static inline int
|
||||
|
||||
Reference in New Issue
Block a user