Skip to content

Commit

Permalink
Merge pull request #228 from JuliaMath/aa/hypotl
Browse files Browse the repository at this point in the history
Fix incorrect results in `hypotl` near underflow
  • Loading branch information
staticfloat authored Feb 17, 2021
2 parents aeab19f + 711654e commit f052f42
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/e_hypotl.c
Original file line number Diff line number Diff line change
Expand Up @@ -82,7 +82,7 @@ hypotl(long double x, long double y)
man_t manh, manl;
GET_LDBL_MAN(manh,manl,b);
if((manh|manl)==0) return a;
t1=0;
t1=1;
SET_HIGH_WORD(t1,ESW(MAX_EXP-2)); /* t1=2^(MAX_EXP-2) */
b *= t1;
a *= t1;
Expand Down

0 comments on commit f052f42

Please sign in to comment.