mirror of
https://git.savannah.gnu.org/git/bison.git
synced 2026-03-11 13:23:04 +00:00
cex: fix reporting of null nonterminals
I implemented this to print A ::= [ ], but A ::= [ %empty ] might be clearer. * src/parse-simulation.c (nullable_closure): Don't generate null nonterminal derivations as leaves. * src/derivation.c (derivation_print_impl): Don't print seperator spaces for null nonterminal. * tests/counterexample.at: Update test results.
This commit is contained in:
committed by
Akim Demaille
parent
3dd8f2305a
commit
69e3b405d9
@@ -426,7 +426,7 @@ nullable_closure (parse_state *ps, state_item *si, parse_state_list state_list)
|
||||
state_item *nsi = state_items + sin;
|
||||
current_ps = copy_parse_state (false, current_ps);
|
||||
ps_si_append (current_ps, nsi);
|
||||
ps_derivs_append (current_ps, derivation_new_leaf (sp));
|
||||
ps_derivs_append (current_ps, derivation_new (sp, derivation_list_new ()));
|
||||
parse_state_list_append (state_list, current_ps);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user