OSDN Git Service

gcc/
[pf3gnuchains/gcc-fork.git] / gcc / testsuite / gcc.dg / return-type-3.c
1 /* PR optimization/7189
2    This was a missing warning caused by a cfg cleanup after sibling
3    call optimization.  The return clobber insn was cleaned up and
4    the warning was never issued.  */
5 /* { dg-do compile } */
6 /* { dg-options "-O -foptimize-sibling-calls -Wreturn-type" } */
7
8 extern void foo(void);
9
10 int
11 bar (void)
12 {
13   foo();
14 } /* { dg-warning "control reaches end of non-void function" "warning for falling off end of non-void function" } */