Re: ZeroDivide bug in float printing

Derek Zhou <[email protected]>
Newsgroups gmane.comp.lang.smalltalk.gnu.general
Message-ID <[email protected]>
Holger Freyther writes:

>> On 29. Mar 2019, at 00:07, Derek Zhou <[email protected]> wrote:
>> 
>> list,
>> 
>
> thanks for looking into it!
>
>
>> There were discussion on this list about this bug in the debian package:
>
> Are you aware of:
>
> http://git.savannah.gnu.org/cgit/smalltalk.git/commit/libgst/interp.inl?id=72ada189aba0283c551ead16635c1983968080b8
That's good; however there are poor poeple still stuck with old
compilers
>> I propose to change 3 into a more conservative and slower test
>> such as:
>> 
>> (MAX_ST_INT / abs(b)) < abs(a) ? OVERFLOW : OK
>
> Overflow checking requires lots of thinking. E.g. have you considered
> where abs(a) < 0? I would prefer if we can exclusively use the compiler
> primitive.
compiler primitives are nice; but there should be fallback path that
also work
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.