* src/lalr.h (state_t): New.

(state_table): Be a state_t * instead of a core **.
(accessing_symbol): Remove, part of state_t.
* src/lalr.c: Adjust.
(set_accessing_symbol): Merge into...
(set_state_table): this.
* src/print_graph.c, src/conflicts.c: Adjust.
This commit is contained in:
Akim Demaille
2001-11-19 10:07:14 +00:00
parent d803322e27
commit 9703cc49e0
7 changed files with 82 additions and 64 deletions

View File

@@ -74,10 +74,23 @@ extern short *LAruleno;
extern unsigned *LA;
/* A structure decorating a state, with additional information. */
typedef struct state_s
{
/* A state. */
core *state;
/* Its accessing symbol. */
short accessing_symbol;
} state_t;
/* All the decorated states, indexed by the state number. Warning:
there is a state_TABLE in LR0.c, but it is different and static.
*/
extern state_t *state_table;
extern int tokensetsize;
extern short *lookaheads;
extern short *accessing_symbol;
extern core **state_table;
extern shifts **shift_table;
extern reductions **reduction_table;