X-Git-Url: http://nsz.repo.hu/git/?a=blobdiff_plain;f=include%2Fmath.h;h=bc0159e63c4d878ce4dad9429975ea2ced0ef9bf;hb=e4d35ea9cfb612bcfbaf141559d62e1dca9f13c4;hp=8791bba807588fd93bf3279aded7bbdcebffedb3;hpb=93a18a15e4428d4fe3f239081e0218ac0c69f458;p=musl diff --git a/include/math.h b/include/math.h index 8791bba8..bc0159e6 100644 --- a/include/math.h +++ b/include/math.h @@ -25,7 +25,7 @@ extern "C" { #define HUGE_VALL ((long double)INFINITY) #define MATH_ERRNO 1 -#define MATH_EXCEPT 2 +#define MATH_ERREXCEPT 2 #define math_errhandling 2 #define FP_ILOGBNAN (((unsigned)-1)>>1) @@ -77,8 +77,8 @@ int __signbitf(float); int __signbitl(long double); #define signbit(x) ( \ - sizeof(x) == sizeof(float) ? !!(__FLOAT_BITS(x) & 0x80000000) : \ - sizeof(x) == sizeof(double) ? !!(__DOUBLE_BITS(x) & (__uint64_t)1<<63) : \ + sizeof(x) == sizeof(float) ? (int)(__FLOAT_BITS(x)>>31) : \ + sizeof(x) == sizeof(double) ? (int)(__DOUBLE_BITS(x)>>63) : \ __signbitl(x) ) #define isunordered(x,y) (isnan((x)) ? ((void)(y),1) : isnan((y)))