This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: AIX bootstrap failure (C++ PATCH: New parser)


	Is something like the following patch correct?

David

	* parser.c (cp_parser_parameter_declaration_clause): Treat system
	header as extern "C" if NO_IMPLICIT_EXTERN_C undefined.

Index: parser.c
===================================================================
RCS file: /cvs/gcc/gcc/gcc/cp/parser.c,v
retrieving revision 1.3
diff -c -p -r1.3 parser.c
*** parser.c	28 Dec 2002 14:38:38 -0000	1.3
--- parser.c	29 Dec 2002 00:28:08 -0000
*************** cp_parser_parameter_declaration_clause (
*** 10558,10564 ****
      }
    else if (token->type == CPP_CLOSE_PAREN)
      /* There are no parameters.  */
!     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 
--- 10558,10572 ----
      }
    else if (token->type == CPP_CLOSE_PAREN)
      /* There are no parameters.  */
!     {
! #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 


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]