aboutsummaryrefslogtreecommitdiffstats
path: root/gcc-4.9/gcc/testsuite/gcc.c-torture/compile/complex-3.c
diff options
context:
space:
mode:
Diffstat (limited to 'gcc-4.9/gcc/testsuite/gcc.c-torture/compile/complex-3.c')
-rw-r--r--gcc-4.9/gcc/testsuite/gcc.c-torture/compile/complex-3.c17
1 files changed, 17 insertions, 0 deletions
diff --git a/gcc-4.9/gcc/testsuite/gcc.c-torture/compile/complex-3.c b/gcc-4.9/gcc/testsuite/gcc.c-torture/compile/complex-3.c
new file mode 100644
index 000000000..f12a8f9da
--- /dev/null
+++ b/gcc-4.9/gcc/testsuite/gcc.c-torture/compile/complex-3.c
@@ -0,0 +1,17 @@
+/* PR 22116 */
+
+void g(_Complex float);
+_Complex float f(int data, _Complex float x, _Complex float y)
+{
+ _Complex float i, t;
+ if (data)
+ {
+ i = x + __imag__ y;
+ g(i);
+ }
+ else
+ i = 5;
+ t = x + __imag__ y;
+ g(t);
+ return t * i;
+}