(QNX 6.2.1 PE)

This is the definition of NAN in “math.h”:

#define NAN (1.0/1.0)

That has a value of 1.0, which would appear to be incorrect.

Nor do you want to write (1.0/0.0). That’s INF, not NAN.

John Nagle

(QNX 6.2.1 PE)

This is the definition of NAN in “math.h”:

#define NAN (1.0/1.0)

That has a value of 1.0, which would appear to be incorrect.

Nor do you want to write (1.0/0.0). That’s INF, not NAN.

John Nagle

(0.0/0.0) would be a good choice, of course.

This is fixed in 6.3.0.

dB

John Nagle wrote ~ Mon, 21 Jun 2004 19:06:18 -0700:

(QNX 6.2.1 PE)

This is the definition of NAN in “math.h”:#define NAN (1.0/1.0)

That has a value of 1.0, which would appear to be incorrect.

Nor do you want to write (1.0/0.0). That’s INF, not NAN.

John Nagle

OK, thanks.

Fortunately, for C++ users, “quiet_NaN()” is defined

correctly for “float” and “double” in “limits”.

John Nagle

David Bacon wrote:

(0.0/0.0) would be a good choice, of course.

This is fixed in 6.3.0.

dB

John Nagle wrote ~ Mon, 21 Jun 2004 19:06:18 -0700:

(QNX 6.2.1 PE)

This is the definition of NAN in “math.h”:#define NAN (1.0/1.0)

That has a value of 1.0, which would appear to be incorrect.

Nor do you want to write (1.0/0.0). That’s INF, not NAN.

John Nagle