Inconsistent definitions of millerrabin() argument types
Case Van Horsen
casevh at gmail.com
Sun Mar 24 06:23:41 CET 2024
Hi,
In millerrabin.c, there are conflicting definitions for millerrabin().
The prototype is:
static int millerrabin (mpz_srcptr,
mpz_ptr, mpz_ptr,
mpz_srcptr, unsigned long int);
while the actual function is:
static int
millerrabin (mpz_srcptr n, mpz_ptr x, mpz_ptr y,
mpz_srcptr q, mp_bitcnt_t k)
I found this with an experimental build of GMP with mp_bitcnt_t defined as
"long long" instead of "long". I understand this is not triggered by an
unpatched version of GMP but it probably should be fixed for correctness.
Regards,
casevh
More information about the gmp-bugs
mailing list