Improvement of assert in longlong.h

Claus Fischer claus.fischer at clausfischer.com
Fri Mar 30 17:35:03 CEST 2007


Dear GMP folks,

I have recently looked into GMP's longlong.h, specifically
the function __udiv_qrnnd_c.

It appears to me the assert in line 1738 of Version 4.2.1
should be changed from

    ASSERT ((d) != 0);

into

    ASSERT ((d) >= __ll_B);

so that the resulting d1 will be nonzero.


Best regards,

Claus Fischer

-- 
Claus Fischer <claus.fischer at clausfischer.com>
http://www.clausfischer.com/


More information about the gmp-discuss mailing list