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: 3.2 PATCH: Properly define __LANGUAGE_C etc. on alpha


Rainer Orth wrote:-

> Ok for mainline?

I'd like some more explanation...

>  	/* Macros dependent on the C dialect.  */	\
>  	if (preprocessing_asm_p ())			\
> -	  builtin_define_std ("LANGUAGE_ASSEMBLY");	\
> +	  {						\
> +	    builtin_define_std ("LANGUAGE_ASSEMBLY");	\
> +	    builtin_define ("__LANGUAGE_ASSEMBLY");	\
> +	    builtin_define ("__LANGUAGE_ASSEMBLY__");	\
> +	  }						\
>          else if (c_language == clk_c)			\
> -	  builtin_define_std ("LANGUAGE_C");		\
> +	  {						\
> +	    builtin_define_std ("LANGUAGE_C");		\
> +	    builtin_define ("__LANGUAGE_C");		\
> +	    builtin_define ("__LANGUAGE_C__");		\
> +	  }						\

The _std call should do these two extra macros for you.  If
not, it's implementation is buggy and needs to be fixed.  At
first glance it should be doing everything you need, so please
explain why the extra macros are not being defined by
builtin_define_std().

Neil.


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