Mombu the Programming Forum sponsored links

Go Back   Mombu the Programming Forum > Programming > NAN in mac and dos - "IsNan.c" 5832 Bytes
User Name
Password
REGISTER NOW! Mark Forums Read

sponsored links


Reply
 
1 8th August 04:21
alex russell
External User
 
Posts: 1
Default NAN in mac and dos - "IsNan.c" 5832 Bytes



--
Alex Russell
alexander.russell@telus.net

I added this test code, and had no errors running it under Borland c / dos
(pentium ii)

Thecode inthe attached snippet does very little floating point math - it is
99% integer math checking the binary format of the double.

I expect the error is in some part of the code that actually DOES floating
point math.

int main()
{
double l, m;

l=2.0;
m=3.0;

if ( IsNan(l) )
printf("isnan\n");
else
printf("is not nan\n");

if ( IsInf(m) )
printf("isinf\n");
else
printf("is not inf\n");

return 0;

}
  Reply With Quote


  sponsored links


Reply


Thread Tools
Display Modes




Copyright © 2006 SmartyDevil.com - Dies Mies Jeschet Boenedoesef Douvema Enitemaus -
666