mirror of
https://git.savannah.gnu.org/git/bison.git
synced 2026-03-20 17:53:02 +00:00
(symbol_new): Report an error if the input grammar contains too many
symbols.
This commit is contained in:
@@ -66,6 +66,9 @@ symbol_new (uniqstr tag, location loc)
|
|||||||
res->alias = NULL;
|
res->alias = NULL;
|
||||||
res->class = unknown_sym;
|
res->class = unknown_sym;
|
||||||
|
|
||||||
|
if (nsyms == SYMBOL_NUMBER_MAXIMUM)
|
||||||
|
fatal (_("too many symbols in input grammar (limit is %d)"),
|
||||||
|
SYMBOL_NUMBER_MAXIMUM);
|
||||||
nsyms++;
|
nsyms++;
|
||||||
return res;
|
return res;
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user