This is the mail archive of the gcc-bugs@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]

[Bug c++/11285] GCC 3.3 C++ for Sparc Solaris assumes system header files are C.


PLEASE REPLY TO gcc-bugzilla@gcc.gnu.org ONLY, *NOT* gcc-bugs@gcc.gnu.org.

http://gcc.gnu.org/bugzilla/show_bug.cgi?id=11285



------- Additional Comments From gdr at integrable-solutions dot net  2003-06-23 07:45 -------
Subject: Re:  GCC 3.3 C++ for Sparc Solaris assumes system header files are C.

"numien at deathwyrm dot net" <gcc-bugzilla@gcc.gnu.org> writes:

| Perhaps I am misunderstanding what you said, but they look fairly C++ aware to
| me...here's a clip from the top of stdio.h...

Indeed.

| I'm using Solaris 9, perhaps they implemented that with this version?
| In which file could I find that value to change? I can test it here.
| 
| ---------------------------------------------------------------------
| <snip>
| /*
|  * Copyright (c) 1993-2001, by Sun Microsystems, Inc.
|  * All rights reserved.
|  */
| <snip>
| /*
|  * Allow global visibility for symbols defined in
|  * C++ "std" namespace in <iso/stdio_iso.h>.
|  */
| #if __cplusplus >= 199711L

Aha, I get it.  Currently g++ (or libstdc++-v3 I can tell which)
defines __cplusplus to 1L because we don't know how to handle Sun's C
system headers which are already C++ aware.  The point is:  In this
specific case, it is not that Sun's are not C++ aware, the problem is
that they *are*, but we don't know how to build libstdc++-v3 with such
systems. Put differently, it is our fault.  The fix is not obbious though.
There should be an open issue related to __cplusplus somewhere in the
archive. 

-- gaby


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