X-Git-Url: https://pintos-os.org/cgi-bin/gitweb.cgi?a=blobdiff_plain;f=src%2Fexpr-prs.c;h=fee00a3e93e1525917485f15cf7726c3a0245f8b;hb=14e7292894533c5491a774a2d749386362660812;hp=046e360f1dfe610a6035a7b5e08ad31295f0affa;hpb=3a7fba81ceae5b049d0f7d671e9e3c3c43bbf703;p=pspp diff --git a/src/expr-prs.c b/src/expr-prs.c index 046e360f1d..fee00a3e93 100644 --- a/src/expr-prs.c +++ b/src/expr-prs.c @@ -32,6 +32,7 @@ #include "str.h" #include "var.h" #include "vfm.h" +#include "pool.h" /* Declarations. */ @@ -81,7 +82,7 @@ expr_free (struct expression *e) free (e->num); free (e->str); free (e->stack); - free (e->str_stack); + pool_destroy (e->pool); free (e); } @@ -690,7 +691,7 @@ static int func_count; static int get_num_args (struct function *, int, union any_node **); static int -unary_func (struct function * f, int x unused, union any_node ** n) +unary_func (struct function * f, int x UNUSED, union any_node ** n) { double divisor; struct nonterm_node *c; @@ -738,7 +739,7 @@ multiply: } static int -binary_func (struct function * f, int x unused, union any_node ** n) +binary_func (struct function * f, int x UNUSED, union any_node ** n) { if (!get_num_args (f, 2, n)) return EX_ERROR; @@ -746,7 +747,7 @@ binary_func (struct function * f, int x unused, union any_node ** n) } static int -ternary_func (struct function * f, int x unused, union any_node ** n) +ternary_func (struct function * f, int x UNUSED, union any_node ** n) { if (!get_num_args (f, 3, n)) return EX_ERROR; @@ -754,7 +755,7 @@ ternary_func (struct function * f, int x unused, union any_node ** n) } static int -MISSING_func (struct function * f, int x unused, union any_node ** n) +MISSING_func (struct function * f, int x UNUSED, union any_node ** n) { if (token == T_ID && dict_lookup_var (default_dict, tokid) != NULL @@ -772,7 +773,7 @@ MISSING_func (struct function * f, int x unused, union any_node ** n) } static int -SYSMIS_func (struct function * f unused, int x unused, union any_node ** n) +SYSMIS_func (struct function * f UNUSED, int x UNUSED, union any_node ** n) { int t; @@ -818,7 +819,7 @@ SYSMIS_func (struct function * f unused, int x unused, union any_node ** n) } static int -VALUE_func (struct function *f unused, int x unused, union any_node **n) +VALUE_func (struct function *f UNUSED, int x UNUSED, union any_node **n) { struct variable *v = parse_variable (); @@ -839,7 +840,7 @@ VALUE_func (struct function *f unused, int x unused, union any_node **n) } static int -LAG_func (struct function *f unused, int x unused, union any_node **n) +LAG_func (struct function *f UNUSED, int x UNUSED, union any_node **n) { struct variable *v = parse_variable (); int nlag = 1; @@ -1040,7 +1041,7 @@ fail: } static int -CONCAT_func (struct function * f unused, int x unused, union any_node ** n) +CONCAT_func (struct function * f UNUSED, int x UNUSED, union any_node ** n) { int m = 0; @@ -1088,7 +1089,7 @@ fail: arg; and `f', format spec (this must be the last arg). If the optional args are included, the type becomes f->t+1. */ static int -generic_str_func (struct function *f, int x unused, union any_node ** n) +generic_str_func (struct function *f, int x UNUSED, union any_node ** n) { int max_args = 0; int type; @@ -1626,7 +1627,7 @@ static struct function func_tab[] = /* An algo_compare_func that compares functions A and B based on their names. */ static int -compare_functions (const void *a_, const void *b_, void *aux unused) +compare_functions (const void *a_, const void *b_, void *aux UNUSED) { const struct function *a = a_; const struct function *b = b_;