2001-03-06 11:17:54 +03:00
|
|
|
/* public domain rewrite of isnan(3) */
|
|
|
|
|
2005-10-22 05:28:00 +04:00
|
|
|
static int double_ne(double n1, double n2);
|
1999-08-13 09:45:20 +04:00
|
|
|
|
|
|
|
int
|
2005-10-22 05:28:00 +04:00
|
|
|
isnan(double n)
|
1999-08-13 09:45:20 +04:00
|
|
|
{
|
2003-12-20 18:45:15 +03:00
|
|
|
return double_ne(n, n);
|
1999-08-13 09:45:20 +04:00
|
|
|
}
|
|
|
|
|
2003-12-20 18:45:15 +03:00
|
|
|
static int
|
2005-10-22 05:28:00 +04:00
|
|
|
double_ne(double n1, double n2)
|
1999-08-13 09:45:20 +04:00
|
|
|
{
|
2003-12-20 18:45:15 +03:00
|
|
|
return n1 != n2;
|
1999-08-13 09:45:20 +04:00
|
|
|
}
|