/* Specification. */
#include <math.h>
+#if HAVE_SAME_LONG_DOUBLE_AS_DOUBLE
+
+long double
+tanl (long double x)
+{
+ return tan (x);
+}
+
+#else
+
+/* Code based on glibc/sysdeps/ieee754/ldbl-128/s_tanl.c
+ and glibc/sysdeps/ieee754/ldbl-128/k_tanl.c. */
+
/* tanl(x)
* Return tangent function of x.
*
* TRIG(x) returns trig(x) nearly rounded
*/
-#include "trigl.h"
-#ifdef HAVE_SINL
-#ifdef HAVE_COSL
-#include "trigl.c"
-#endif
-#endif
+# include "trigl.h"
/*
* ====================================================
/* 1.000000000000000000000000000000000000000E0 */
-long double
+static long double
kernel_tanl (long double x, long double y, int iy)
{
long double z, r, v, w, s, u, u1;
}
}
+#endif
+
#if 0
int
main (void)
{
- printf ("%.16Lg\n", tanl(0.7853981633974483096156608458198757210492));
- printf ("%.16Lg\n", tanl(-0.7853981633974483096156608458198757210492));
- printf ("%.16Lg\n", tanl(0.7853981633974483096156608458198757210492 *3));
- printf ("%.16Lg\n", tanl(-0.7853981633974483096156608458198757210492 *31));
- printf ("%.16Lg\n", tanl(0.7853981633974483096156608458198757210492 / 2));
- printf ("%.16Lg\n", tanl(0.7853981633974483096156608458198757210492 * 3/2));
- printf ("%.16Lg\n", tanl(0.7853981633974483096156608458198757210492 * 5/2));
+ printf ("%.16Lg\n", tanl (0.7853981633974483096156608458198757210492));
+ printf ("%.16Lg\n", tanl (-0.7853981633974483096156608458198757210492));
+ printf ("%.16Lg\n", tanl (0.7853981633974483096156608458198757210492 *3));
+ printf ("%.16Lg\n", tanl (-0.7853981633974483096156608458198757210492 *31));
+ printf ("%.16Lg\n", tanl (0.7853981633974483096156608458198757210492 / 2));
+ printf ("%.16Lg\n", tanl (0.7853981633974483096156608458198757210492 * 3/2));
+ printf ("%.16Lg\n", tanl (0.7853981633974483096156608458198757210492 * 5/2));
}
#endif