* doc/bison.texinfo (Bison Options): Add entry for --print-datadir.

(Option Cross Key): Likewise.

* src/print-xml.c (print_core): Don't print a reduction's lookahead set
next to an item whose dot is not at the end of the RHS even if it
happens to be associated with the same rule.
* src/print.c (print_core): Likewise.
* tests/conflicts.at (Unresolved SR Conflicts): Update output.
(Resolved SR Conflicts): Update output.
* tests/regression.at (Extra lookahead sets in report): New test case.
This commit is contained in:
Joel E. Denny
2007-10-17 04:35:35 +00:00
parent 4c20d18dc1
commit a0de5091fc
6 changed files with 63 additions and 4 deletions

View File

@@ -122,7 +122,8 @@ print_core (FILE *out, int level, state *s)
sp = rules[r].rhs;
/* Display the lookahead tokens? */
if (report_flag & report_lookahead_tokens)
if (report_flag & report_lookahead_tokens
&& item_number_is_rule_number (*sp1))
{
reductions *reds = s->reductions;
int red = state_reduction_find (s, &rules[r]);

View File

@@ -110,7 +110,8 @@ print_core (FILE *out, state *s)
fprintf (out, " %s", symbols[*sp]->tag);
/* Display the lookahead tokens? */
if (report_flag & report_lookahead_tokens)
if (report_flag & report_lookahead_tokens
&& item_number_is_rule_number (*sp1))
state_rule_lookahead_tokens_print (s, &rules[r], out);
fputc ('\n', out);