90 |
|
|
91 |
# include "bitsetv.h" |
# include "bitsetv.h" |
92 |
|
|
93 |
|
|
94 |
|
/*-------------------. |
95 |
|
| Numbering states. | |
96 |
|
`-------------------*/ |
97 |
|
|
98 |
|
typedef short state_number_t; |
99 |
|
# define STATE_NUMBER_MAX ((state_number_t) SHRT_MAX) |
100 |
|
|
101 |
|
/* Be ready to map a state_number_t to an int. */ |
102 |
|
# define state_number_as_int(Tok) ((int) (Tok)) |
103 |
|
|
104 |
/*---------. |
/*---------. |
105 |
| Shifts. | |
| Shifts. | |
106 |
`---------*/ |
`---------*/ |
108 |
typedef struct shifts |
typedef struct shifts |
109 |
{ |
{ |
110 |
short nshifts; |
short nshifts; |
111 |
short shifts[1]; |
state_number_t shifts[1]; |
112 |
} shifts; |
} shifts; |
113 |
|
|
114 |
shifts *shifts_new PARAMS ((int n)); |
shifts *shifts_new PARAMS ((int n)); |
182 |
struct state_s *next; |
struct state_s *next; |
183 |
struct state_s *link; |
struct state_s *link; |
184 |
|
|
185 |
short number; |
state_number_t number; |
186 |
symbol_number_t accessing_symbol; |
symbol_number_t accessing_symbol; |
187 |
shifts *shifts; |
shifts *shifts; |
188 |
reductions *reductions; |
reductions *reductions; |