summaryrefslogtreecommitdiff
path: root/src/complex/_Complex_I.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/complex/_Complex_I.c')
-rw-r--r--src/complex/_Complex_I.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/complex/_Complex_I.c b/src/complex/_Complex_I.c
index 0cb6aede..a250d031 100644
--- a/src/complex/_Complex_I.c
+++ b/src/complex/_Complex_I.c
@@ -1,6 +1,8 @@
#include <complex.h>
-#define _Complex_I (const float _Complex)1 /* TODO: imaginary unit */
+#define _Complex_I \
+ (((union { _Complex float __c; float __f[2]; }){.__f = {0., 1.} }).__c)
+
/*
STDC(199901)