[Cfp-interest 1838] Negative zero
Fred J. Tydeman
tydeman at tybor.com
Mon Nov 9 09:49:12 PST 2020
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?
---
Fred J. Tydeman Tydeman Consulting
tydeman at tybor.com Testing, numerics, programming
+1 (702) 608-6093 Vice-chair of PL22.11 (ANSI "C")
Sample C99+FPCE tests: http://www.tybor.com
Savers sleep well, investors eat well, spenders work forever.
More information about the Cfp-interest
mailing list