cii icon indicating copy to clipboard operation
cii copied to clipboard

Ch18 - Arbitrary Precision: AP_toint problem

Open ylme opened this issue 5 years ago • 0 comments

AP_T x = AP_new(LONG_MIN);
long val = AP_toint(x); // The val is 0

AP_toint turn LONG_MIN to 0 . https://github.com/drh/cii/blob/master/src/ap.c#L323 can use without %.

unsigned long u = XP_toint(x->ndigits, x->digits);

ylme avatar Nov 05 '19 11:11 ylme