cex: prefer → to ::=

It does not make a lot of sense to use ::= in our counterexamples,
that's not something that belongs to the Bison "vocabulary".  Using
the colon makes sense, but it's too discreet.  Let's use the arrow,
which we already use in some reports (HTML and Dot).

* src/gram.h (print_dot_fallback): Generalize into...
(print_fallback): this.
(print_arrow): New.
* src/derivation.c: Use it.

* NEWS, tests/conflicts.at, tests/counterexample.at,
* tests/diagnostics.at, tests/report.at: Adjust.
* doc/bison.texi: Ditto.
Unfortunately the literal `→` is output as `↦`.  So we need to use
@arrow.
This commit is contained in:
Akim Demaille
2020-07-11 18:25:49 +02:00
parent a2ad33dca6
commit ee86ea8839
8 changed files with 147 additions and 125 deletions

View File

@@ -145,7 +145,9 @@ derivation_print_impl (const derivation *deriv, FILE *f,
{
fputs (prefix, f);
begin_use_class ("cex-step", f);
fprintf (f, "%s ::=[ ", sym->tag);
fprintf (f, "%s ", sym->tag);
print_arrow (f);
fprintf (f, " [ ");
end_use_class ("cex-step", f);
prefix = "";
}