diff -r branch-2.5/src/graphviz.c branch-2.5a/src/graphviz.c 29a30,32 > static int n_nodes = 0; > static int n_edges = 0; > 41a45,46 > n_nodes = 0; > n_edges = 0; 45a51,52 > "// Shifts are solid, gotos are dashed, and error are dotted edge lines.\n" > "// Shifts are blue, gotos are green, and error are red colored edge lines.\n" 59c66,67 < fprintf (fout, " %d [label=%s]\n", id, quote (label)); --- > n_nodes = n_nodes + 1; > fprintf (fout, " \"%d\" [label=%s]\n", id, quote (label)); 64c72 < char const *style, FILE *fout) --- > char const *style, char const *color, FILE *fout) 66c74,75 < fprintf (fout, " %d -> %d [style=%s", source, destination, style); --- > n_edges = n_edges + 1; > fprintf (fout, " \"%d\" -> \"%d\" [style=%s,color=\"%s\"", source, destination, style, color); 68c77 < fprintf (fout, " label=%s", quote (label)); --- > fprintf (fout, ",label=%s", quote (label)); 75a85 > fprintf (fout, "// %d nodes and %d edges in this bison graph\n", n_nodes, n_edges); diff -r branch-2.5/src/graphviz.h branch-2.5a/src/graphviz.h 40a41 > /// \param color Dot color of the edge (e.g., "red" or "green" or "blue"). 43c44 < char const *style, FILE *fout); --- > char const *style, char const *color, FILE *fout); diff -r branch-2.5/src/print_graph.c branch-2.5a/src/print_graph.c 136a137,142 > /* Shifts are blue, gotos are green, and error is red. */ > char const *color = > (TRANSITION_IS_ERROR (trans, i) ? "red" > : TRANSITION_IS_SHIFT (trans, i) ? "blue" > : "green"); > 142c148 < style, fgraph); --- > style, color, fgraph);