diff options
author | Manuel López-Ibáñez <manu@gcc.gnu.org> | 2007-05-20 00:45:58 +0000 |
---|---|---|
committer | Manuel López-Ibáñez <manu@gcc.gnu.org> | 2007-05-20 00:45:58 +0000 |
commit | ffd5f2761323eea74743302bfdbff644eceae83b (patch) | |
tree | bbcc1e2ae00d84751fb6d9e0d94ad59c5dd5ae75 /gcc/testsuite/gcc.dg/20030906-1.c | |
parent | 05ce201275137ae82ced2edc32c43acf9fea37d7 (diff) | |
download | gcc-ffd5f2761323eea74743302bfdbff644eceae83b.zip gcc-ffd5f2761323eea74743302bfdbff644eceae83b.tar.gz gcc-ffd5f2761323eea74743302bfdbff644eceae83b.tar.bz2 |
re PR middle-end/7651 (Define -Wextra strictly in terms of other warning flags)
2006-05-20 Manuel Lopez-Ibanez <manu@gcc.gnu.org>
PR middle-end/7651
* doc/invoke.texi (Wreturn-type): Complete description.
(Wextra): Delete item about return-type warning.
* c-decl.c: Delete redundant Wextra warning.
testsuite/
* gcc.dg/20030906-1.c: Replace Wextra with Wreturn-type.
* gcc.dg/20030906-2.c: Likewise.
* objc.dg/method-17.m: Add -Wreturn-type.
* obj-c++.dg/method-21.mm: Likewise.
From-SVN: r124866
Diffstat (limited to 'gcc/testsuite/gcc.dg/20030906-1.c')
-rw-r--r-- | gcc/testsuite/gcc.dg/20030906-1.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/gcc/testsuite/gcc.dg/20030906-1.c b/gcc/testsuite/gcc.dg/20030906-1.c index 57d80f0..c416f55 100644 --- a/gcc/testsuite/gcc.dg/20030906-1.c +++ b/gcc/testsuite/gcc.dg/20030906-1.c @@ -2,7 +2,7 @@ Copyright (C) 2003 Free Software Foundation Inc. */ /* { dg-do compile } */ -/* { dg-options "-O -finline-functions -Wextra" } */ +/* { dg-options "-O -finline-functions -Wreturn-type" } */ extern int i; extern int foo (void); @@ -12,10 +12,10 @@ int foo (void) { if( i ) return 0; else return 1; -} /* { dg-bogus "may return with or without a value" } */ +} int bar (void) { - if( i ) return; + if( i ) return; /* { dg-warning "'return' with no value, in function returning non-void" } */ else return 1; -} /* { dg-warning "may return with or without a value" } */ +} |