From 6255b435119f729b0a7d27d581b75b9e71a0b89c Mon Sep 17 00:00:00 2001 From: Akim Demaille Date: Fri, 23 Nov 2001 14:13:20 +0000 Subject: [PATCH] * src/print_graph.c (print_actions): Remove `rule', unused. * src/LR0.c (kernel_size): Contain `int' instead of `size_t' to pacify GCC's signed < unsigned warnings. * src/closure.c (itemsetsize): Likewise. * src/reader.c (symbol_list_new): Static. --- ChangeLog | 9 +++++++++ src/LR0.c | 4 +--- src/closure.c | 2 +- src/closure.h | 2 +- src/print_graph.c | 1 - src/reader.c | 2 +- 6 files changed, 13 insertions(+), 7 deletions(-) diff --git a/ChangeLog b/ChangeLog index d761d03a..188e80c7 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,12 @@ +2001-11-23 Akim Demaille + + * src/print_graph.c (print_actions): Remove `rule', unused. + * src/LR0.c (kernel_size): Contain `int' instead of `size_t' to + pacify GCC's signed < unsigned warnings. + * src/closure.c (itemsetsize): Likewise. + * src/reader.c (symbol_list_new): Static. + + 2001-11-23 Akim Demaille Attaching lineno to buckets is stupid, since only one copy of each diff --git a/src/LR0.c b/src/LR0.c index 8d424eab..d7edc283 100644 --- a/src/LR0.c +++ b/src/LR0.c @@ -50,7 +50,7 @@ static short *redset = NULL; static short *shiftset = NULL; static short **kernel_base = NULL; -static size_t *kernel_size = NULL; +static int *kernel_size = NULL; static short *kernel_items = NULL; /* hash table for states, to recognize equivalent ones. */ @@ -213,7 +213,6 @@ static int get_state (int symbol) { int key; - short *isp2; int i; core *sp; @@ -236,7 +235,6 @@ get_state (int symbol) { if (sp->nitems == kernel_size[symbol]) { - int i; found = 1; for (i = 0; i < kernel_size[symbol]; ++i) if (kernel_base[symbol][i] != sp->items[i]) diff --git a/src/closure.c b/src/closure.c index ab086342..593aedf8 100644 --- a/src/closure.c +++ b/src/closure.c @@ -28,7 +28,7 @@ /* ITEMSETSIZE is the size of the array ITEMSET. */ short *itemset; -size_t itemsetsize; +int itemsetsize; static unsigned *ruleset; diff --git a/src/closure.h b/src/closure.h index 67759a48..887f3da8 100644 --- a/src/closure.h +++ b/src/closure.h @@ -51,6 +51,6 @@ void closure PARAMS ((short *items, int n)); void free_closure PARAMS ((void)); extern short *itemset; -extern size_t itemsetsize; +extern int itemsetsize; #endif /* !CLOSURE_H_ */ diff --git a/src/print_graph.c b/src/print_graph.c index 7caba6f8..4d95a587 100644 --- a/src/print_graph.c +++ b/src/print_graph.c @@ -90,7 +90,6 @@ print_actions (int state, const char *node_name) shifts *shiftp; errs *errp; reductions *redp; - int rule; static char buff[10]; edge_t edge; diff --git a/src/reader.c b/src/reader.c index 30e7f581..d3c08951 100644 --- a/src/reader.c +++ b/src/reader.c @@ -66,7 +66,7 @@ static bucket *errtoken; static bucket *undeftoken; -symbol_list * +static symbol_list * symbol_list_new (bucket *sym) { symbol_list *res = XMALLOC (symbol_list, 1); -- 2.45.2