mirror of
https://git.savannah.gnu.org/git/bison.git
synced 2026-03-11 21:33:04 +00:00
Kill GCC warnings.
* src/reduce.c (nonterminals_reduce): Don't loop over RITEM: loop over the RHS of each rule. * src/gram.h, src/gram.c (nritems): Is `unsigned int', not int. * src/state.h (state_t): Member `nitems' is unsigned short. * src/LR0.c (get_state): Adjust. * src/reader.c (packgram): Likewise. * src/output.c (GENERATE_MUSCLE_INSERT_TABLE): `max' is of type `Type'. (muscle_insert_int_table): Remove, unused. (prepare_rules): Remove `max'.
This commit is contained in:
@@ -29,7 +29,7 @@
|
||||
/* comments for these variables are in gram.h */
|
||||
|
||||
item_number_t *ritem = NULL;
|
||||
int nritems = 0;
|
||||
unsigned int nritems = 0;
|
||||
|
||||
rule_t *rules = NULL;
|
||||
int nrules = 0;
|
||||
@@ -70,7 +70,7 @@ rule_rhs_length (rule_t *rule)
|
||||
void
|
||||
ritem_print (FILE *out)
|
||||
{
|
||||
int i;
|
||||
unsigned int i;
|
||||
fputs ("RITEM\n", out);
|
||||
for (i = 0; i < nritems; ++i)
|
||||
if (ritem[i] >= 0)
|
||||
|
||||
Reference in New Issue
Block a user