gcl-devel
[Top][All Lists]
Advanced

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

Re: [Gcl-devel] Re: [Maxima] float to bfloat


From: Richard Fateman
Subject: Re: [Gcl-devel] Re: [Maxima] float to bfloat
Date: Fri, 30 Jan 2004 11:01:15 -0800
User-agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.4) Gecko/20030624 Netscape/7.1 (ax)



Raymond Toy wrote:



I don't think I would want my Lisp to be able to integer-decode-float
a double-float positive infinity, assuming that that is what (expt
9.9d0 9999) has returned.
I disagree:
That means any almost user of integer-decode-float must guard the call by a check to see if the argument is inf or nan, and in case it IS an nan, with no way to decode its fraction, which may in in fact have valuable information. e.g. the program counter when it was produced, or a pointer into a hash-table of a diagnostic message, etc. So if integer-decode-float does not decompose a NaN into pieces, someone intent on using NaNs would have to write a program exactly like integer-decode-float. (I've gone this route, actually..)

 You can't store extra information in Inf, but
still, you should not have to check for it specially, in my view.

RJF






reply via email to

[Prev in Thread] Current Thread [Next in Thread]