diff options
author | Jakob Kaivo <jkk@ung.org> | 2022-03-28 16:49:13 -0400 |
---|---|---|
committer | Jakob Kaivo <jkk@ung.org> | 2022-03-28 16:49:13 -0400 |
commit | 0c061784519c069853ba9e9794fc4ec41d0668f9 (patch) | |
tree | 0f6f2732d5319bb8a5df36ee875d63653183ac1e /big.c | |
parent | b7220bcd1a054872e081afc77b305f0247bf3f98 (diff) |
rename bigzero() to big_is_zero()
Diffstat (limited to 'big.c')
-rw-r--r-- | big.c | 16 |
1 files changed, 8 insertions, 8 deletions
@@ -419,7 +419,7 @@ long long big_toll(word x) word big_negate(word x) { - if (bigzero(x)) { + if (big_is_zero(x)) { return x; } @@ -506,7 +506,7 @@ word big_multiply(word x, word y) word r = make(INT, 0, 0); /* short cut */ - if (bigzero(x)) { + if (big_is_zero(x)) { return (r); } @@ -542,7 +542,7 @@ word big_divide(word x, word y) word q = bd.quo; if (s2) { - if (!bigzero(bd.rem)) { + if (!big_is_zero(bd.rem)) { x = q; while ((digit(x) += 1) == IBASE) { /* add 1 to q in situ */ digit(x) = 0; @@ -553,7 +553,7 @@ word big_divide(word x, word y) x = rest(x); } } - if (!bigzero(q)) { + if (!big_is_zero(q)) { digit(q) = SIGNBIT | digit(q); } } @@ -581,7 +581,7 @@ word big_remainder(word x, word y) struct big_div bd = rest(y) ? big__longdiv(x, y) : big__shortdiv(x, digit(y)); if (s2) { - if (!bigzero(bd.rem)) { + if (!big_is_zero(bd.rem)) { bd.rem = big_subtract(y, bd.rem); } } @@ -695,7 +695,7 @@ static double big__log(word x, double logbase, char *name, double (*fn)(double)) word n = 0; double r = digit(x); - if (big_is_negative(x) || bigzero(x)) { + if (big_is_negative(x) || big_is_zero(x)) { errno = EDOM; math_error(name); } @@ -772,7 +772,7 @@ word bigscan(char *p) } } - if (s && !bigzero(r)) { + if (s && !big_is_zero(r)) { digit(r) = digit(r) | SIGNBIT; } @@ -889,7 +889,7 @@ word strtobig(word z, int base) } } - if (s && !bigzero(r)) { + if (s && !big_is_zero(r)) { digit(r) = digit(r) | SIGNBIT; } |