incubator-stdcxx-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Martin Sebor <se...@roguewave.com>
Subject Re: STDCXX examples fails and reasons [MSVC]
Date Fri, 22 Jun 2007 14:58:20 GMT
Farid Zaripov wrote:
>> -----Original Message-----
>> From: Martin Sebor [mailto:sebor@roguewave.com] 
>> Sent: Thursday, June 21, 2007 8:56 PM
>> To: stdcxx-dev@incubator.apache.org
>> Subject: Re: STDCXX examples fails and reasons [MSVC]
>  
> [...]
> 
>> limits.cpp should produce the qnan for Quiet NAN and snan for
>> Signaling NAN on all platforms.
> 
>   I can't find this requirement in standard.

It's not in the C++ standard but it is in C99, under fprintf(),
the f and F conversion specifier:

     A double argument representing an infinity is converted
     in one of the styles [-]inf or [-]infinity — which style
     is implementation-defined. A double argument representing
     a NaN is converted in one of the styles [-]nan or
     [-]nan(n-char-sequence) — which style, and the meaning
     of any n-char-sequence, is implementation-defined. The
     F conversion specifier produces INF, INFINITY, or NAN
     instead of inf, infinity, or nan, respectively.

Martin

Mime
View raw message