changed hcl_mulints() a little bit
This commit is contained in:
parent
c447bde889
commit
de44f7e57c
@ -1797,6 +1797,7 @@ hcl_oop_t hcl_mulints (hcl_t* hcl, hcl_oop_t x, hcl_oop_t y)
|
|||||||
else
|
else
|
||||||
{
|
{
|
||||||
hcl_ooi_t v;
|
hcl_ooi_t v;
|
||||||
|
int neg;
|
||||||
|
|
||||||
if (HCL_OOP_IS_SMOOI(x))
|
if (HCL_OOP_IS_SMOOI(x))
|
||||||
{
|
{
|
||||||
@ -1845,13 +1846,10 @@ hcl_oop_t hcl_mulints (hcl_t* hcl, hcl_oop_t x, hcl_oop_t y)
|
|||||||
}
|
}
|
||||||
|
|
||||||
normal:
|
normal:
|
||||||
hcl_pushtmp (hcl, &x);
|
neg = (HCL_OBJ_GET_FLAGS_BRAND(x) != HCL_OBJ_GET_FLAGS_BRAND(y));
|
||||||
hcl_pushtmp (hcl, &y);
|
|
||||||
z = multiply_unsigned_integers (hcl, x, y);
|
z = multiply_unsigned_integers (hcl, x, y);
|
||||||
hcl_poptmps (hcl, 2);
|
|
||||||
if (!z) return HCL_NULL;
|
if (!z) return HCL_NULL;
|
||||||
if (HCL_OBJ_GET_FLAGS_BRAND(x) != HCL_OBJ_GET_FLAGS_BRAND(y))
|
if (neg) HCL_OBJ_SET_FLAGS_BRAND (z, HCL_BRAND_NBIGINT);
|
||||||
HCL_OBJ_SET_FLAGS_BRAND (z, HCL_BRAND_NBIGINT);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
return normalize_bigint (hcl, z);
|
return normalize_bigint (hcl, z);
|
||||||
|
Loading…
Reference in New Issue
Block a user