decl.c (grokfndecl): Remove redundant use of in_system_header_at.
authorPaolo Carlini <paolo.carlini@oracle.com>
Thu, 17 Oct 2019 20:00:38 +0000 (20:00 +0000)
committerPaolo Carlini <paolo@gcc.gnu.org>
Thu, 17 Oct 2019 20:00:38 +0000 (20:00 +0000)
commitac4c7868f1032bb9184cd9a59ee17845f6f456c6
tree087cdb040fedacacd6a432cb39fa755b1100c9e9
parent8228c8f2a54be12c70070d4eb2cd64483782b138
decl.c (grokfndecl): Remove redundant use of in_system_header_at.

/cp
2019-10-17  Paolo Carlini  <paolo.carlini@oracle.com>

* decl.c (grokfndecl): Remove redundant use of in_system_header_at.
(compute_array_index_type_loc): Likewise.
(grokdeclarator): Likewise.
* error.c (cp_printer): Likewise.
* lambda.c (add_default_capture): Likewise.
* parser.c (cp_parser_primary_expression): Likewise.
(cp_parser_selection_statement): Likewise.
(cp_parser_toplevel_declaration): Likewise.
(cp_parser_enumerator_list): Likewise.
(cp_parser_using_declaration): Likewise.
(cp_parser_member_declaration): Likewise.
(cp_parser_exception_specification_opt): Likewise.
(cp_parser_std_attribute_spec): Likewise.
* pt.c (do_decl_instantiation): Likewise.
(do_type_instantiation): Likewise.
* typeck.c (cp_build_unary_op): Likewise.

* decl.c (check_tag_decl): Pass to in_system_header_at the same
location used for the permerror.
(grokdeclarator): Likewise.

* decl.c (check_tag_decl): Use locations[ds_typedef] in error_at.

/testsuite
2019-10-17  Paolo Carlini  <paolo.carlini@oracle.com>

* g++.old-deja/g++.other/decl9.C: Check locations too.

From-SVN: r277133
gcc/cp/ChangeLog
gcc/cp/decl.c
gcc/cp/error.c
gcc/cp/lambda.c
gcc/cp/parser.c
gcc/cp/pt.c
gcc/cp/typeck.c
gcc/testsuite/ChangeLog
gcc/testsuite/g++.old-deja/g++.other/decl9.C