summaryrefslogtreecommitdiff
path: root/mpq
diff options
context:
space:
mode:
authortege <tege@gmplib.org>2002-04-29 14:44:11 +0200
committertege <tege@gmplib.org>2002-04-29 14:44:11 +0200
commit24dadb0bfcd122a0410f9f9abe71affb1aa36598 (patch)
treebbb9884a966d268e8d0e0b3ff10df02ce0b9f4b5 /mpq
parentf1642675b3da33751e0a610f312575a1504b5009 (diff)
downloadgmp-24dadb0bfcd122a0410f9f9abe71affb1aa36598.tar.gz
Nailify.
Diffstat (limited to 'mpq')
-rw-r--r--mpq/cmp.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/mpq/cmp.c b/mpq/cmp.c
index 16248e33d..34176efde 100644
--- a/mpq/cmp.c
+++ b/mpq/cmp.c
@@ -74,11 +74,11 @@ mpq_cmp (const MP_RAT *op1, const MP_RAT *op2)
count_leading_zeros (cnt1, op1->_mp_num._mp_d[num1_size - 1]);
count_leading_zeros (cnt2, op2->_mp_den._mp_d[den2_size - 1]);
- bits1 = tmp1_size * BITS_PER_MP_LIMB - cnt1 - cnt2;
+ bits1 = tmp1_size * GMP_NUMB_BITS - cnt1 - cnt2 + 2 * GMP_NAIL_BITS;
count_leading_zeros (cnt1, op2->_mp_num._mp_d[num2_size - 1]);
count_leading_zeros (cnt2, op1->_mp_den._mp_d[den1_size - 1]);
- bits2 = tmp2_size * BITS_PER_MP_LIMB - cnt1 - cnt2;
+ bits2 = tmp2_size * GMP_NUMB_BITS - cnt1 - cnt2 + 2 * GMP_NAIL_BITS;
if (bits1 > bits2 + 1)
return num1_sign;