[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: arithmetic issues

This page is part of the web mail archives of SRFI 77 from before July 7th, 2015. The new archives for SRFI 77 contain all messages, not just those from before July 7th, 2015.



   Date: Mon, 24 Oct 2005 04:08:32 +0200
   From: Marcin 'Qrczak' Kowalczyk <qrczak@xxxxxxxxxx>

   Taylor Campbell <campbell@xxxxxxxxxx> writes:

   > CL conditions *are* comparable to NaN.

   No, because they are passed out of band. They are not returned as
   results of arithmetic operations nor accepted by arithmetic. So they
   won't be printed along with other numeric results, and it makes no
   sense to read them back in place of numbers.

Did you read what I wrote?  CL conditions do *not* exist only if they
are immediately signalled out-of-band; they can exist in-band in any
situation you want.  Likewise, NaN is a condition of numerical
operations, which, for the sake of floating-point efficiency, it is
convenient in some contexts to allow along with other numerical
results.  But NaN conditions can be signalled like error conditions
can be; this is typically what is done with exact arithmetic, such as
in Scheme48:

(/ 0 0)     => Error: rational division by zero
                      0