A little warning in GMP.h

Patrick Pelissier Patrick.Pelissier at loria.fr
Thu Sep 23 13:17:09 CEST 2004


> Anyway, I was wondering if just writing
> 
>       return __gmp_l & (-(signed)(mp_limb_t) (__gmp_n != 0));
> 
> would work, since this would solve the problem with all compilers without
> any option tweak....

 Some problems may occur if sizeof(int) != sizeof (mp_limb_t) (16 or 64 bits systems).

 Patrick



More information about the gmp-discuss mailing list