X-Git-Url: http://nsz.repo.hu/git/?a=blobdiff_plain;f=src%2Fmath%2Fsqrt.c;h=2ebd022b0c3cb73ca4300fb5da24072f7a61da1f;hb=405a21d4cbce255eefd2b59626d8459d7d1108d4;hp=2c5642e30f80869836b2e1c04970626ee9af29c9;hpb=fc04675a09587031d5daebcb877b73976890b71d;p=libm diff --git a/src/math/sqrt.c b/src/math/sqrt.c index 2c5642e..2ebd022 100644 --- a/src/math/sqrt.c +++ b/src/math/sqrt.c @@ -74,9 +74,6 @@ * sqrt(inf) = inf * sqrt(-ve) = NaN ... with invalid signal * sqrt(NaN) = NaN ... with invalid signal for signaling NaN - * - * Other methods : see the appended file at the end of the program below. - *--------------- */ #include "libm.h" @@ -98,7 +95,7 @@ double sqrt(double x) } /* take care of zero */ if (ix0 <= 0) { - if (((ix0&(~sign))|ix1) == 0) + if (((ix0&~sign)|ix1) == 0) return x; /* sqrt(+-0) = +-0 */ if (ix0 < 0) return (x-x)/(x-x); /* sqrt(-ve) = sNaN */