diff options
Diffstat (limited to 'gcc/testsuite/gcc.dg/pr30045.c')
-rw-r--r-- | gcc/testsuite/gcc.dg/pr30045.c | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/gcc/testsuite/gcc.dg/pr30045.c b/gcc/testsuite/gcc.dg/pr30045.c new file mode 100644 index 000000000..6dd22a1df --- /dev/null +++ b/gcc/testsuite/gcc.dg/pr30045.c @@ -0,0 +1,15 @@ +/* { dg-do compile } */ +/* { dg-options "-O2 -fno-inline" } */ +int f(int *a) +{ + int __attribute__((nonnull(1))) g(int *b) + { + int **c = &a; + if (b) + return *a + **c; + return *b; + } + if (a) + return g(a); + return 1; +} |