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