diff options
author | Kaz Kylheku <kaz@kylheku.com> | 2021-05-21 06:51:20 -0700 |
---|---|---|
committer | Kaz Kylheku <kaz@kylheku.com> | 2021-05-21 06:51:20 -0700 |
commit | a8af1ac53edacc13d47dd5ab6ca33b6b90f9f537 (patch) | |
tree | ed9af1da5a5bdee00dada4107ba9d47128adfbf3 /tests/016/arith.tl | |
parent | be5103ccf9c9b49e471f09e004f9521236c35b25 (diff) | |
download | txr-a8af1ac53edacc13d47dd5ab6ca33b6b90f9f537.tar.gz txr-a8af1ac53edacc13d47dd5ab6ca33b6b90f9f537.tar.bz2 txr-a8af1ac53edacc13d47dd5ab6ca33b6b90f9f537.zip |
mpi: bug in range test predictes.
* mpi/mpi.c (mp_in_range, s_mp_in_big_range): The ptrnd
calculation here is wrong; it adds together dissimilar units:
bits and bytes. In the case of mp_in_range, we are okay by
fluke, because the calculation works out to 1 anyway. We would
not be okay of a mp_digit was half the size of a pointer.
In s_mp_in_big_range we have a problem. On 32 bit platforms,
ptrnd is wrongly calculated as 1 rather than 2, and so values
perfectly in range are rejected.
Diffstat (limited to 'tests/016/arith.tl')
0 files changed, 0 insertions, 0 deletions