diff options
Diffstat (limited to 'gcc-4.9/gcc/testsuite/gcc.dg/Wreturn-type2.c')
-rw-r--r-- | gcc-4.9/gcc/testsuite/gcc.dg/Wreturn-type2.c | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/gcc-4.9/gcc/testsuite/gcc.dg/Wreturn-type2.c b/gcc-4.9/gcc/testsuite/gcc.dg/Wreturn-type2.c new file mode 100644 index 000000000..781414a1a --- /dev/null +++ b/gcc-4.9/gcc/testsuite/gcc.dg/Wreturn-type2.c @@ -0,0 +1,9 @@ +/* Test for cases that should not get the unconditional warning about + missing return. */ +/* { dg-do compile } */ + +extern void abort (void); + +f() {} /* { dg-bogus "" "no return warning" } */ +int g() { abort (); } /* { dg-bogus "" "no return warning" } */ +int main() {} /* { dg-bogus "" "no return warning" } */ |