diff --git a/gcc/testsuite/ChangeLog b/gcc/testsuite/ChangeLog index a4b62de4099..434e539b005 100644 --- a/gcc/testsuite/ChangeLog +++ b/gcc/testsuite/ChangeLog @@ -1,3 +1,8 @@ +2005-09-12 Josh Conner + + PR middle-end/23237 + * gcc.c-torture/compile/pr23237.c: New test. + 2005-09-11 Richard Henderson * g++.dg/other/error8.C: Update expected diagnostic text. diff --git a/gcc/testsuite/gcc.c-torture/compile/pr23237.c b/gcc/testsuite/gcc.c-torture/compile/pr23237.c new file mode 100644 index 00000000000..bbb3483a557 --- /dev/null +++ b/gcc/testsuite/gcc.c-torture/compile/pr23237.c @@ -0,0 +1,12 @@ +/* { dg-require-effective-target named_sections } */ + +static __attribute__ ((__section__ (".init.data"))) char *message; +static __attribute__ ((__section__ (".init.data"))) int (*actions[])(void) = {}; +void unpack_to_rootfs(void) +{ + while (!message) + { + if(!actions[0]) + return; + } +}