aboutsummaryrefslogtreecommitdiff
path: root/gcc/testsuite/gcc.c-torture/execute/pr70005.c
diff options
context:
space:
mode:
Diffstat (limited to 'gcc/testsuite/gcc.c-torture/execute/pr70005.c')
-rw-r--r--gcc/testsuite/gcc.c-torture/execute/pr70005.c25
1 files changed, 25 insertions, 0 deletions
diff --git a/gcc/testsuite/gcc.c-torture/execute/pr70005.c b/gcc/testsuite/gcc.c-torture/execute/pr70005.c
new file mode 100644
index 00000000000..bc37efe00cb
--- /dev/null
+++ b/gcc/testsuite/gcc.c-torture/execute/pr70005.c
@@ -0,0 +1,25 @@
+
+unsigned char a = 6;
+int b, c;
+
+static void
+fn1 ()
+{
+ int i = a > 1 ? 1 : a, j = 6 & (c = a && (b = a));
+ int d = 0, e = a, f = ~c, g = b || a;
+ unsigned char h = ~a;
+ if (a)
+ f = j;
+ if (h && g)
+ d = a;
+ i = -~(f * d * h) + c && (e || i) ^ f;
+ if (i != 1)
+ __builtin_abort ();
+}
+
+int
+main ()
+{
+ fn1 ();
+ return 0;
+}