mirror of
https://git.savannah.gnu.org/git/bison.git
synced 2026-03-15 23:33:03 +00:00
warnings: factoring: complaints
* src/complain.c (error_message): Accept warning categories (an integer) as argument. Location is a 'const location *' instead of 'location *'. (ERROR_MESSAGE): Delete it. * src/complain.c, src/complain.h (complains): New function. (complain, complain_at, complain_at_indent): Generic functions for complaints. Call 'complains'. (warn_at, warn_at_indent, warn, yacc_at, midrule_value_at) (fatal_at, fatal): Delete them. Adjust dependencies. * src/complain.h (enum warnings): New fields 'complaint' and 'fatal'. * bootstrap.conf (XGETTEXT_OPTIONS): Adjust.
This commit is contained in:
committed by
Akim Demaille
parent
d0f11c1b62
commit
6fb8b25619
@@ -24,7 +24,6 @@
|
||||
#include "complain.h"
|
||||
#include "symlist.h"
|
||||
|
||||
|
||||
/*--------------------------------------.
|
||||
| Create a list containing SYM at LOC. |
|
||||
`--------------------------------------*/
|
||||
@@ -212,7 +211,7 @@ symbol_list_n_type_name_get (symbol_list *l, location loc, int n)
|
||||
l = symbol_list_n_get (l, n);
|
||||
if (!l)
|
||||
{
|
||||
complain_at (loc, _("invalid $ value: $%d"), n);
|
||||
complain_at (loc, complaint, _("invalid $ value: $%d"), n);
|
||||
return NULL;
|
||||
}
|
||||
aver (l->content_type == SYMLIST_SYMBOL);
|
||||
|
||||
Reference in New Issue
Block a user