mirror of
https://gcc.gnu.org/git/gcc.git
synced 2024-12-04 09:14:04 +08:00
parser.c (cp_parser_parameter_declaration_clause): Treat system header as extern "C" if NO_IMPLICIT_EXTERN_C undefined.
* parser.c (cp_parser_parameter_declaration_clause): Treat system header as extern "C" if NO_IMPLICIT_EXTERN_C undefined. From-SVN: r60639
This commit is contained in:
parent
b599b13591
commit
c73aecdfc0
@ -1,3 +1,8 @@
|
||||
2002-12-30 David Edelsohn <edelsohn@gnu.org>
|
||||
|
||||
* parser.c (cp_parser_parameter_declaration_clause): Treat system
|
||||
header as extern "C" if NO_IMPLICIT_EXTERN_C undefined.
|
||||
|
||||
2002-12-30 Nathanael Nerode <neroden@gcc.gnu.org>
|
||||
|
||||
* config-lang.in, Make-lang.in, operators.def, cp-tree.def:
|
||||
|
@ -10558,7 +10558,15 @@ cp_parser_parameter_declaration_clause (parser)
|
||||
}
|
||||
else if (token->type == CPP_CLOSE_PAREN)
|
||||
/* There are no parameters. */
|
||||
return void_list_node;
|
||||
{
|
||||
#ifndef NO_IMPLICIT_EXTERN_C
|
||||
if (in_system_header && current_class_type == NULL
|
||||
&& current_lang_name == lang_name_c)
|
||||
return NULL_TREE;
|
||||
else
|
||||
#endif
|
||||
return void_list_node;
|
||||
}
|
||||
/* Check for `(void)', too, which is a special case. */
|
||||
else if (token->keyword == RID_VOID
|
||||
&& (cp_lexer_peek_nth_token (parser->lexer, 2)->type
|
||||
|
Loading…
Reference in New Issue
Block a user