summaryrefslogtreecommitdiff
path: root/src/complex/cabs.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/complex/cabs.c')
-rw-r--r--src/complex/cabs.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/complex/cabs.c b/src/complex/cabs.c
index 3e2d1ac8..f98ec907 100644
--- a/src/complex/cabs.c
+++ b/src/complex/cabs.c
@@ -1,11 +1,12 @@
# define TGSOURCE "../complex/cabs.c"
#include "_tgmath.h"
+#include "math.h"
#include <complex.h>
TYPE TGFN(cabs)(TYPE complex z)
{
- return z;
+ return TGFN(hypot)(TGFN(creal)(z), TGFN(cimag)(z));
}
/*d