[cfp-interest 3693] Re: [SC22WG14.34225] Annex F signaling NaN recommendation versus "domain error"

Jim Thomas jaswthomas at sbcglobal.net
Tue Nov 4 09:44:04 PST 2025


Annex F doesn’t specify errno which is not an ISO/IEC 60559 feature. There is not a strict alignment of floating-point exceptions and errno setting. In several cases Annex F requires floating-point exceptions without requiring corresponding errno setting, e.g. see pow. Introducing such a requirement would almost surely invalidate implementations. An intention of Annex F is not to preclude implementations from aligning errno and exceptions wherever it makes sense, including in the recommended practice in F.2.2. 

- Jim Thomas


> On Oct 30, 2025, at 1:24 PM, Hubert Tong <hubert.reinterpretcast at gmail.com> wrote:
> 
> Hi all,
> 
> N3685 subclause F.2.2 paragraph 6 recommends for signaling NaN inputs to raise the "invalid" floating-point exception "unless explicitly stated otherwise".
> 
> Subclause 7.12.2 paragraph 3 separately makes it implementation-defined whether a signaling NaN input is treated as a domain error.
> 
> That the recommended practice does not explicitly align the errno and non-errno treatment seems unfortunate.
> 
> -- HT
> 




More information about the cfp-interest mailing list