diff options
Diffstat (limited to 'gcc/testsuite/gcc.dg/torture/pr59715.c')
-rw-r--r-- | gcc/testsuite/gcc.dg/torture/pr59715.c | 21 |
1 files changed, 21 insertions, 0 deletions
diff --git a/gcc/testsuite/gcc.dg/torture/pr59715.c b/gcc/testsuite/gcc.dg/torture/pr59715.c new file mode 100644 index 00000000000..19c09de55d7 --- /dev/null +++ b/gcc/testsuite/gcc.dg/torture/pr59715.c @@ -0,0 +1,21 @@ +/* { dg-do run } */ + +extern void abort (void); + +int a = 2, b; + +int +main () +{ + int c; + if (!b) + { + b = a; + c = a == 0 ? 1 : 1 % a; + if (c) + b = 0; + } + if (b != 0) + abort (); + return 0; +} |