chicken-users
[Top][All Lists]
Advanced

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

Re: [Chicken-users] expt incorrect in boundary cases


From: John Cowan
Subject: Re: [Chicken-users] expt incorrect in boundary cases
Date: Tue, 28 Apr 2009 13:29:44 -0400
User-agent: Mutt/1.5.13 (2006-08-11)

fulvio ciriaco scripsit:

> No, not a bug with the definition.  It depends on libm.

That's why I say it's a spec bug.  The SUS specifies what libm does in
this case, and specifies the Wrong Thing.  Or, if you like, there is a
conflict between specs.

If you think about it, multiplying -1 by itself an infinite number of
times might return -1 or 1, depending on if infinity is an odd number
or an even number; so NaN is a sensible response.  I don't know what
the motivation for (expt 1.0 +inf) being NaN is.

-- 
There are three kinds of people in the world:   John Cowan
those who can count,                            address@hidden
and those who can't.




reply via email to

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