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] | |
Hello,
For targets that do not define NO_IMPLICIT_EXTERN_C, GCC assumes that
included system headers are implicitly wrapped in 'extern "C" {...}'.
I could not find where this target macro was introduced, but it is
very old (it is already mentioned in FSFChangeLog.10 for a change in
1995). AFAICT, today all supported targets have C++-compatible headers
(according to one comment, even hpux8 had C++-compatible system
headers :-), so NO_IMPLICIT_EXTERN_C shouldn't be necessary anymore.
The only target that explicitly undefines NO_IMPLICIT_EXTERN_C is
sparc64-openbsd, and I find it hard to believe that the system headers
on openbsd are not also already C++-compatible. Marc, could you have a
look at this, please?
The attached patch removes NO_IMPLICIT_EXTERN_C, and replaces its sole
user with IMPLICIT_EXTERN_C to avoid the double negations (#ifndef
NO_IMPLICIT_EXTERN_C, etc.).
Bootstrapped and tested on x86_64-unknown-linux-gnu. OK for trunk?
Ciao!
Steven
Attachment:
fixup_NO_IMPLICIT_EXTERN_C.diff
Description: Binary data
| Index Nav: | [Date Index] [Subject Index] [Author Index] [Thread Index] | |
|---|---|---|
| Message Nav: | [Date Prev] [Date Next] | [Thread Prev] [Thread Next] |