Print this page
@@ -58,10 +58,11 @@
* tanhl(NaN) is NaN;
* only tanhl(0.0)=0.0 is exact for finite argument.
*/
#include "libm.h"
+#include "longdouble.h"
static const long double small = 1.0e-20L, one = 1.0, two = 2.0,
#ifndef lint
big = 1.0e+20L,
#endif
@@ -69,10 +70,11 @@
long double
tanhl(long double x) {
long double t, y, z;
int signx;
+ volatile long double dummy;
if (isnanl(x))
return (x + x); /* x is NaN */
signx = signbitl(x);
t = fabsl(x);
@@ -83,11 +85,11 @@
else if (t > small) {
y = expm1l(-t - t);
z = -y / (y + two);
} else {
#ifndef lint
- volatile long double dummy = t + big;
+ dummy = t + big;
/* inexact if t != 0 */
#endif
return (x);
}
} else if (!finitel(t))