summaryrefslogtreecommitdiff
path: root/big.c
diff options
context:
space:
mode:
Diffstat (limited to 'big.c')
-rw-r--r--big.c16
1 files changed, 8 insertions, 8 deletions
diff --git a/big.c b/big.c
index 35f27b5..120748b 100644
--- a/big.c
+++ b/big.c
@@ -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;
}