mirror of
https://git.savannah.gnu.org/git/bison.git
synced 2026-03-13 14:23:04 +00:00
* src/LR0.c (generate_states): Use nritems, not nitems, nor using
the 0-sentinel. * src/gram.c (ritem_longest_rhs): Likewise. * src/reduce.c (nonterminals_reduce): Likewise. * src/print_graph.c (print_graph): Likewise. * src/output.c (output_rule_data): Likewise. * src/nullable.c (set_nullable): Likewise.
This commit is contained in:
@@ -294,7 +294,7 @@ output_rule_data (void)
|
||||
short_tab = XMALLOC (short, nrules + 1);
|
||||
for (i = 1; i < nrules; i++)
|
||||
short_tab[i] = rule_table[i + 1].rhs - rule_table[i].rhs - 1;
|
||||
short_tab[nrules] = nitems - rule_table[nrules].rhs - 1;
|
||||
short_tab[nrules] = nritems - rule_table[nrules].rhs - 1;
|
||||
output_table_data (&format_obstack, short_tab,
|
||||
0, 1, nrules + 1);
|
||||
muscle_insert ("r2", obstack_finish (&format_obstack));
|
||||
|
||||
Reference in New Issue
Block a user