+static void
+conclude_red (struct obstack *out, int source, int ruleno, bool enabled,
+ bool first, FILE *fout)
+{
+ /* If no lookahead tokens were valid transitions, this reduction is
+ actually hidden, so cancel everything. */
+ if (first)
+ return (void) obstack_finish0 (out);
+ else
+ {
+ char const *ed = enabled ? "e" : "d";
+
+ /* First, build the edge's head. */
+ if (! first)
+ fprintf (fout, " %1$d -> \"%1$dR%2$d%3$s\" [label = \"",
+ source, ruleno, ed);
+
+ /* (The lookahead tokens have been added to the beginning of the
+ obstack, in the caller function.) */
+
+ /* Then, the edge's tail. */
+ obstack_sgrow (out, "\" style = solid]\n");
+
+ /* Build the associated diamond representation or the target rule. */
+ obstack_printf (out, " \"%dR%d%s\" "
+ "[style = filled shape = diamond fillcolor = %s "
+ "label = \"R%d\"]\n",
+ source, ruleno, ed,
+ enabled ? "yellowgreen" : "firebrick1",
+ ruleno);
+ fprintf (fout, obstack_finish0 (out));
+ }
+}
+