decl.c (warn_extern_redeclared_static): Use the location of newdecl in diagnostics...
authorJason Merrill <jason@redhat.com>
Wed, 27 May 2015 20:52:55 +0000 (16:52 -0400)
committerJason Merrill <jason@gcc.gnu.org>
Wed, 27 May 2015 20:52:55 +0000 (16:52 -0400)
commitf425298902b6a36fef278c01610afb58dceaec89
tree8269ddf1d0aef464dcc47583931bb7f030cbb742
parent929614bf0e95a91e48fd892956fabc68dcfbd58d
decl.c (warn_extern_redeclared_static): Use the location of newdecl in diagnostics, not input_location.

* decl.c (warn_extern_redeclared_static): Use the location of
newdecl in diagnostics, not input_location.
(validate_constexpr_redeclaration): Likewise.
(check_redeclaration_no_default_args): Likewise.
(duplicate_decls): Likewise.
(check_redeclaration_exception_specification): Likewise.
Change second diagnostic to inform.

From-SVN: r223777
gcc/cp/ChangeLog
gcc/cp/decl.c
gcc/testsuite/g++.dg/cpp0x/noexcept02.C
gcc/testsuite/g++.dg/eh/spec8.C
gcc/testsuite/g++.dg/ext/attrib51.C [new file with mode: 0644]
gcc/testsuite/g++.dg/other/error3.C
gcc/testsuite/g++.dg/template/error36.C
gcc/testsuite/g++.old-deja/g++.eh/spec6.C