diff options
Diffstat (limited to 'newlib/libm/math/w_hypot.c')
-rw-r--r-- | newlib/libm/math/w_hypot.c | 22 |
1 files changed, 2 insertions, 20 deletions
diff --git a/newlib/libm/math/w_hypot.c b/newlib/libm/math/w_hypot.c index 533702277..441fc20cb 100644 --- a/newlib/libm/math/w_hypot.c +++ b/newlib/libm/math/w_hypot.c @@ -41,8 +41,6 @@ RETURNS <<hypot>> returns <<HUGE_VAL>> and sets <<errno>> to <<ERANGE>>. - You can change the error treatment with <<matherr>>. - PORTABILITY <<hypot>> and <<hypotf>> are not ANSI C. */ @@ -66,7 +64,6 @@ PORTABILITY return __ieee754_hypot(x,y); #else double z; - struct exception exc; z = __ieee754_hypot(x,y); if(_LIB_VERSION == _IEEE_) return z; if((!finite(z))&&finite(x)&&finite(y)) { @@ -77,23 +74,8 @@ PORTABILITY SET_HIGH_WORD(inf,0x7ff00000); /* set inf to infinite */ #endif - exc.type = OVERFLOW; - exc.name = "hypot"; - exc.err = 0; - exc.arg1 = x; - exc.arg2 = y; - if (_LIB_VERSION == _SVID_) - exc.retval = HUGE; - else - exc.retval = HUGE_VAL; - if (_LIB_VERSION == _POSIX_) - errno = ERANGE; - else if (!matherr(&exc)) { - errno = ERANGE; - } - if (exc.err != 0) - errno = exc.err; - return exc.retval; + errno = ERANGE; + return HUGE_VAL; } else return z; #endif |