/* Type definitions for nondeterministic finite state machine for Bison.
- Copyright (C) 2001, 2002, 2003, 2004 Free Software Foundation, Inc.
+ Copyright (C) 2001, 2002, 2003, 2004, 2005 Free Software Foundation, Inc.
This file is part of Bison, the GNU Compiler Compiler.
void
state_transitions_set (state *s, int num, state **trans)
{
- if (s->transitions)
- abort ();
+ assert (!s->transitions);
s->transitions = transitions_new (num, trans);
}
void
state_reductions_set (state *s, int num, rule **reds)
{
- if (s->reductions)
- abort ();
+ assert (!s->reductions);
s->reductions = reductions_new (num, reds);
}
bitset_iterator biter;
int k;
char const *sep = "";
- fputs (" [", out);
+ fprintf (out, " [");
BITSET_FOR_EACH (biter, reds->look_ahead_tokens[red], k, 0)
{
fprintf (out, "%s%s", sep, symbols[k]->tag);
sep = ", ";
}
- fputc (']', out);
+ fprintf (out, "]");
}
}
-/*----------------------.
+/*---------------------.
| A state hash table. |
-`----------------------*/
+`---------------------*/
/* Initial capacity of states hash table. */
#define HT_INITIAL_CAPACITY 257