might want to accurately divide large negative fixnums too
parent
6f65b2869e
commit
03c1c916e0
|
|
@ -229,3 +229,4 @@ unit-test
|
|||
|
||||
! Ensure that /f is accurate for fixnums > 2^53 on 64-bit platforms
|
||||
[ HEX: 1.758bec11492f9p-54 ] [ 1 12345678901234567 /f ] unit-test
|
||||
[ HEX: -1.758bec11492f9p-54 ] [ 1 -12345678901234567 /f ] unit-test
|
||||
|
|
|
|||
|
|
@ -41,7 +41,7 @@ CONSTANT: bignum/f-threshold HEX: 20,0000,0000,0000
|
|||
[ >float ] bi@ float/f ; inline
|
||||
|
||||
M: fixnum /f
|
||||
2dup [ bignum/f-threshold >= ] either?
|
||||
2dup [ abs bignum/f-threshold >= ] either?
|
||||
[ bignum/f ] [ fixnum/f ] if ; inline
|
||||
|
||||
M: fixnum mod fixnum-mod ; inline
|
||||
|
|
|
|||
Loading…
Reference in New Issue