[Top][All Lists]

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

Re: [Gcl-devel] RE: GCL bugs (decode-float, rationalize, expt)

From: Camm Maguire
Subject: Re: [Gcl-devel] RE: GCL bugs (decode-float, rationalize, expt)
Date: 09 Jan 2003 21:35:41 -0500


"Stavros Macrakis" <address@hidden> writes:

> Camm,
> That was a quick fix!  Thanks!  What turned out to be the problem?

The issue was that Ldecode_float/double_exponent/set_exponent used
their own bit masking code, and did not use that in
integer-decode-float at all.  This together with the fact that certain
algorithms calculated their result inverted and then divided into
1.0 at the end, which of course will overflow when a double is

Take care,

> > ;; although the following is correct code in that it approximates the
> > ;; x to within eps, it does not preserve (eql (float (rationalize x)
> x) x)
> > ;; since the test for eql is more strict than the float-epsilon
> I agree that the spec for rationalize is ambiguous, and making it behave
> better is not high priority.  But the comment in numlib.lsp doesn't make
> sense, because (float (rationalize x)) should be *precisely* equal to
> x -- I'm afraid I can't look at the code in more detail right now.
> Anyway, this is not a high priority.
> Thanks again!
>       -s

Camm Maguire                                            address@hidden
"The earth is but one country, and mankind its citizens."  --  Baha'u'llah

reply via email to

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