X-Git-Url: https://pintos-os.org/cgi-bin/gitweb.cgi?a=blobdiff_plain;f=src%2Ffrequencies.q;h=44393a89bbe765ad473afaa63a1af1a4cc72a9f5;hb=e22db86f67a3b77124af022bbd734922c62c424c;hp=d1a75f72e347046c4c272f3aba410a61c3e4aff2;hpb=7b98b3a4f58f6dc5a8e9cbc188b627966d5e652d;p=pspp diff --git a/src/frequencies.q b/src/frequencies.q index d1a75f72e3..44393a89bb 100644 --- a/src/frequencies.q +++ b/src/frequencies.q @@ -160,9 +160,9 @@ static struct pool *gen_pool; /* General mode. */ static void determine_charts (void); -static void precalc (void); -static int calc (struct ccase *); -static void postcalc (void); +static void precalc (void *); +static int calc (struct ccase *, void *); +static void postcalc (void *); static void postprocess_freq_tab (struct variable *); static void dump_full (struct variable *); @@ -246,7 +246,7 @@ internal_cmd_frequencies (void) cmd.sort = FRQ_AVALUE; /* Do it! */ - procedure (precalc, calc, postcalc); + procedure (precalc, calc, postcalc, NULL); return CMD_SUCCESS; } @@ -355,7 +355,7 @@ determine_charts (void) /* Add data from case C to the frequency table. */ static int -calc (struct ccase *c) +calc (struct ccase *c, void *aux UNUSED) { double weight; int i; @@ -408,7 +408,7 @@ calc (struct ccase *c) /* Prepares each variable that is the target of FREQUENCIES by setting up its hash table. */ static void -precalc (void) +precalc (void *aux UNUSED) { int i; @@ -451,7 +451,7 @@ precalc (void) /* Finishes up with the variables after frequencies have been calculated. Displays statistics, percentiles, ... */ static void -postcalc (void) +postcalc (void *aux UNUSED) { int i; @@ -889,9 +889,9 @@ compare_freq_numeric_a (const void *a_, const void *b_, void *foo UNUSED) const struct freq *a = a_; const struct freq *b = b_; - if (a->v.c > b->v.c) + if (a->c > b->c) return 1; - else if (a->v.c < b->v.c) + else if (a->c < b->c) return -1; if (a->v.f > b->v.f) @@ -911,9 +911,9 @@ compare_freq_alpha_a (const void *a_, const void *b_, void *v_) const struct freq *b = b_; const struct variable *v = v_; - if (a->v.c > b->v.c) + if (a->c > b->c) return 1; - else if (a->v.c < b->v.c) + else if (a->c < b->c) return -1; else return memcmp (a->v.s, b->v.s, v->width); @@ -927,9 +927,9 @@ compare_freq_numeric_d (const void *a_, const void *b_, void *foo UNUSED) const struct freq *a = a_; const struct freq *b = b_; - if (a->v.c > b->v.c) + if (a->c > b->c) return -1; - else if (a->v.c < b->v.c) + else if (a->c < b->c) return 1; if (a->v.f > b->v.f) @@ -949,9 +949,9 @@ compare_freq_alpha_d (const void *a_, const void *b_, void *v_) const struct freq *b = b_; const struct variable *v = v_; - if (a->v.c > b->v.c) + if (a->c > b->c) return -1; - else if (a->v.c < b->v.c) + else if (a->c < b->c) return 1; else return memcmp (a->v.s, b->v.s, v->width);