[Cfp-interest 1839] Re: Negative zero

Damian McGuckin damianm at esi.com.au
Mon Nov 9 13:16:12 PST 2020


On Mon, 9 Nov 2020, Fred J. Tydeman wrote:

> C in <math.h> 7.12.7.5 The pow functions has:
> A domain error occurs if x is finite and negative
> and y is finite and not an integer value.
>
> Is -0.0 negative?
> Is pow(-0.0, 1.5) a domain error?
>
> F.10.4.5 The pow functions has:
> pow(?0, y) returns +0 for y > 0 and not an odd integer.
>
> Should "negative" be changed to "less than zero" in the above?

I just re-read the standard and it is covered but it will need more words 
to cover all cases. unless someone else gets in before me with a concise 
statement, I will send something later today (or tonight for those in 
Europe or and the US).

Regards - Damian

Pacific Engineering Systems International, 277-279 Broadway, Glebe NSW 2037
Ph:+61-2-8571-0847 .. Fx:+61-2-9692-9623 | unsolicited email not wanted here
Views & opinions here are mine and not those of any past or present employer


More information about the Cfp-interest mailing list