Ensure bignum sign field is initialized

Stil have a bigger question of how to set it properly when doing bignum subtraction. But this avoids any downstream issues.
This commit is contained in:
Justin Ethier 2022-06-23 13:33:44 -04:00
parent 267137fc68
commit 45b435a342

View file

@ -3209,6 +3209,7 @@ object bignum_minus_unsigned(void *data, object x, object y)
break;
}
res = gc_alloc_bignum2(data, size);
C_bignum_sign(res) = 0; // JAE TODO: this initializes sign, but how to we properly set sign when doing bignum subtraction?
scan_r = C_bignum_digits(res);
end_r = scan_r + C_bignum_size(res);