This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug c/53066] Wshadow should not warn for shadowing an extern function
- From: "manu at gcc dot gnu.org" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: Mon, 29 Oct 2012 20:17:34 +0000
- Subject: [Bug c/53066] Wshadow should not warn for shadowing an extern function
- Auto-submitted: auto-generated
- References: <bug-53066-4@http.gcc.gnu.org/bugzilla/>
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=53066
--- Comment #2 from Manuel LÃpez-IbÃÃez <manu at gcc dot gnu.org> 2012-10-29 20:17:34 UTC ---
Author: manu
Date: Mon Oct 29 20:17:23 2012
New Revision: 192963
URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=192963
Log:
2012-10-29 Manuel LÃpez-IbÃÃez <manu@gcc.gnu.org>
PR c/53066
c/
* c-decl.c (warn_if_shadowing): Do not warn if a variable
shadows a function, unless the variable is a function or a
pointer-to-function.
gcc/
* tree.h (FUNCTION_POINTER_TYPE_P): New.
testsuite/
* gcc.dg/Wshadow-4.c: New.
* gcc.dg/Wshadow-4.h: New.
Added:
trunk/gcc/testsuite/gcc.dg/Wshadow-4.c
trunk/gcc/testsuite/gcc.dg/Wshadow-4.h
Modified:
trunk/gcc/ChangeLog
trunk/gcc/c/ChangeLog
trunk/gcc/c/c-decl.c
trunk/gcc/testsuite/ChangeLog
trunk/gcc/tree.h