summaryrefslogtreecommitdiffstats
path: root/libc-top-half/musl/src/complex/clogl.c
diff options
context:
space:
mode:
Diffstat (limited to 'libc-top-half/musl/src/complex/clogl.c')
-rw-r--r--libc-top-half/musl/src/complex/clogl.c18
1 files changed, 18 insertions, 0 deletions
diff --git a/libc-top-half/musl/src/complex/clogl.c b/libc-top-half/musl/src/complex/clogl.c
new file mode 100644
index 0000000..88e83e8
--- /dev/null
+++ b/libc-top-half/musl/src/complex/clogl.c
@@ -0,0 +1,18 @@
+#include "complex_impl.h"
+
+#if LDBL_MANT_DIG == 53 && LDBL_MAX_EXP == 1024
+long double complex clogl(long double complex z)
+{
+ return clog(z);
+}
+#else
+// FIXME
+long double complex clogl(long double complex z)
+{
+ long double r, phi;
+
+ r = cabsl(z);
+ phi = cargl(z);
+ return CMPLXL(logl(r), phi);
+}
+#endif