Windows has no _isnanl, _isinfl functions

svn path=/trunk/; revision=54431
This commit is contained in:
Pierre Schweitzer 2011-11-19 09:46:40 +00:00
parent 84212a76b6
commit 47536a6d8e

View file

@ -19,7 +19,6 @@
#include <precomp.h>
/*
* @implemented
*/
@ -34,26 +33,6 @@ int _isnan(double __x)
return ( x.x->exponent == 0x7ff && ( x.x->mantissah != 0 || x.x->mantissal != 0 ));
}
int _isnanl(long double __x)
{
/* Intel's extended format has the normally implicit 1 explicit
present. Sigh! */
union
{
long double* __x;
long_double_s* x;
} x;
x.__x = &__x;
/* IEEE 854 NaN's have the maximum possible
exponent and a nonzero mantissa. */
return (( x.x->exponent == 0x7fff)
&& ( (x.x->mantissah & 0x80000) != 0)
&& ( (x.x->mantissah & (unsigned int)0x7fffffff) != 0 || x.x->mantissal != 0 ));
}
/*
* @implemented
*/
@ -69,25 +48,3 @@ int _finite(double __x)
return ((x.x->exponent & 0x7ff) != 0x7ff);
}
int _isinfl(long double __x)
{
/* Intel's extended format has the normally implicit 1 explicit
present. Sigh! */
union
{
long double* __x;
long_double_s* x;
} x;
x.__x = &__x;
/* An IEEE 854 infinity has an exponent with the
maximum possible value and a zero mantissa. */
if ( x.x->exponent == 0x7fff && ( (x.x->mantissah == 0x80000 ) && x.x->mantissal == 0 ))
return x.x->sign ? -1 : 1;
return 0;
}