mirror of
https://git.savannah.gnu.org/git/bison.git
synced 2026-03-15 15:23:02 +00:00
obstacks: simplifications
* src/system.h (obstack_finish0): New. Use it to simplify several uses. * src/muscle-tab.h (MUSCLE_INSERTF): New. * src/muscle-tab.c: Use obstack_printf where simpler.
This commit is contained in:
@@ -155,8 +155,7 @@ print_state (state *s, FILE *fgraph)
|
||||
/* A node's label contains its items. */
|
||||
obstack_init (&node_obstack);
|
||||
print_core (&node_obstack, s);
|
||||
obstack_1grow (&node_obstack, '\0');
|
||||
output_node (s->number, obstack_finish (&node_obstack), fgraph);
|
||||
output_node (s->number, obstack_finish0 (&node_obstack), fgraph);
|
||||
obstack_free (&node_obstack, 0);
|
||||
|
||||
/* Output the edges. */
|
||||
|
||||
Reference in New Issue
Block a user