Using GMP for BigIntegers.

Per Bothner per@bothner.com
Tue Jan 30 15:33:00 GMT 2001


"Mark J. Roberts" <mjr@statesmean.com> writes:

> I read I have to declare it as unsigned, like:
> 
> unsigned(var) >>= 10;

> It compiles, but is it right?

I don't know. At the very least it is confusing.
I suggest:
   carry = (uint64_t) carry >> 32;
(where unit64_t is defined in stdint.h).

> And
> udiv_qrnnd (jlong N, jint D)
> 
> doesn't seem to be available either: the comment says it was copied from
> GMP 2.0--maybe it's obsolete. Is there a substitute?

It's a macro defined in longlong.h.
-- 
	--Per Bothner
per@bothner.com   http://www.bothner.com/~per/


More information about the Java mailing list