This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: cpplib: Fix __cplusplus definition
Phil Edwards wrote:-
> While cleaning out my mailbox, I found that old discussion that Neil
> discovered in Google. There was also a followup from Zack at the time:
>
> > Would extending STDC_0_IN_SYSTEM_HEADERS help here? Presently on
> > Solaris cpp causes __STDC__ to be 1 in user code and 0 in system headers.
> > It would be easy to apply that to __cplusplus as well, so it would be
> > 199711L in user code and 1 or 0 in the headers.
>
> Neil, did you see this in the archives? Does it still apply?
No and yes.
> Is this the way we want to go? I'm still wavering between "try to make
> use of their attempt at standards compliance" and "just subvert the whole
> mess to our indomitable will".
I don't know. I'd rather we don't hack it if possible.
I don't understand what the STDC_0... macro works around either - I've
never used a Solaris box.
Neil.