* src/data.c (Fmod): Use mpz_sgn.
* src/lisp.h (NATNUMP): Use mpz_sgn.
mpz_mod (result, *xmp, *ymp);
/* Fix the sign if needed. */
- cmpr = mpz_cmp_si (result, 0);
- cmpy = mpz_cmp_si (*ymp, 0);
+ cmpr = mpz_sgn (result);
+ cmpy = mpz_sgn (*ymp);
if (cmpy < 0 ? cmpr > 0 : cmpr < 0)
mpz_add (result, result, *ymp);
NATNUMP (Lisp_Object x)
{
if (BIGNUMP (x))
- return mpz_cmp_si (XBIGNUM (x)->value, 0) >= 0;
+ return mpz_sgn (XBIGNUM (x)->value) >= 0;
return FIXNUMP (x) && 0 <= XFIXNUM (x);
}
INLINE bool