[m-rev.] for review: float__pow: accept negative exponent; Russian peasants alg

Fergus Henderson fjh at cs.mu.OZ.AU
Fri Mar 1 14:44:28 AEDT 2002


On 28-Feb-2002, Peter Moulder <pmoulder at csse.monash.edu.au> wrote:
> As regards what should stay in the actual code, I'm inclined not
> to leave any comments justifying handling negative exponents,

Fine.

> and re the 0.0**0 question either have no comment or, if convenient,
> either a reference to an authoritative source (is it in Knuth's Art of
> Programming?) or a URL to mailing list discussion.

The authoratitive source in this case is probably the ISO LIA-2 standard.
I suggest just the following:

	Note that LIA-2 (the ISO Language Independent Arithmetic standard,
	part 2) requires that for pow(float, int) = float, pow(0.0, 0) = 1.0.

-- 
Fergus Henderson <fjh at cs.mu.oz.au>  |  "I have always known that the pursuit
The University of Melbourne         |  of excellence is a lethal habit"
WWW: <http://www.cs.mu.oz.au/~fjh>  |     -- the last words of T. S. Garp.
--------------------------------------------------------------------------
mercury-reviews mailing list
post:  mercury-reviews at cs.mu.oz.au
administrative address: owner-mercury-reviews at cs.mu.oz.au
unsubscribe: Address: mercury-reviews-request at cs.mu.oz.au Message: unsubscribe
subscribe:   Address: mercury-reviews-request at cs.mu.oz.au Message: subscribe
--------------------------------------------------------------------------



More information about the reviews mailing list