summaryrefslogtreecommitdiff
path: root/big.c
diff options
context:
space:
mode:
authorJakob Kaivo <jkk@ung.org>2022-03-28 16:37:33 -0400
committerJakob Kaivo <jkk@ung.org>2022-03-28 16:37:33 -0400
commitb685352ab7b7567064725a13c8cc92e71010aa6f (patch)
tree489821c61b9b9fa64d55e8a58bcc14d9e8e8b305 /big.c
parent5e3239b785ecd81cf9451d4da420dca916a00ad4 (diff)
rename bigsub() to big_subtract()
Diffstat (limited to 'big.c')
-rw-r--r--big.c12
1 files changed, 6 insertions, 6 deletions
diff --git a/big.c b/big.c
index 675635a..e895def 100644
--- a/big.c
+++ b/big.c
@@ -188,7 +188,7 @@ static struct big_div big__longdiv(word x, word y)
} else if (lx == ly) {
if (big_compare(x, y) >= 0) {
- x = bigsub(x, y);
+ x = big_subtract(x, y);
d = 1;
} else {
d = 0;
@@ -201,15 +201,15 @@ static struct big_div big__longdiv(word x, word y)
}
if ((d -= 2) > 0) {
- x = bigsub(x, big__stimes(y, d));
+ x = big_subtract(x, big__stimes(y, d));
} else {
d = 0;
}
if (big_compare(x, y) >= 0) {
- x = bigsub(x, y), d++;
+ x = big_subtract(x, y), d++;
if (big_compare(x, y) >= 0) {
- x = bigsub(x, y);
+ x = big_subtract(x, y);
d++;
}
}
@@ -446,7 +446,7 @@ word big_add(word x, word y)
}
-word bigsub(word x, word y)
+word big_subtract(word x, word y)
{
if (big_is_positive(x)) {
if (big_is_positive(y)) {
@@ -582,7 +582,7 @@ word big_remainder(word x, word y)
if (s2) {
if (!bigzero(bd.rem)) {
- bd.rem = bigsub(y, bd.rem);
+ bd.rem = big_subtract(y, bd.rem);
}
}