* Fw: /usr/include/asm/system.h
@ 2002-05-21 12:37 Claude Lamy
2002-05-21 12:48 ` Dave Jones
0 siblings, 1 reply; 3+ messages in thread
From: Claude Lamy @ 2002-05-21 12:37 UTC (permalink / raw)
To: linux-kernel
----- Original Message -----
From: "Rupert Wood" <me@rupey.net>
To: "'Claude Lamy'" <clamy@sunrisetelecom.com>
Cc: <gcc-help@gcc.gnu.org>
Sent: Thursday, May 09, 2002 8:12 AM
Subject: RE: /usr/include/asm/system.h
> Claude Lamy wrote:
>
> > I am running a Mandrake 8.1 linux distribution with gcc 2.96. In
> > the file /usr/include/asm/system.h, the function __cmpxchg uses a
> > parameter named "new" which is a reserved keyword in C++. I can
> > modify the header file for myself but I think it should be changed (if
not
> > already) for future releases.
>
> Actually the system headers belong to the system C library and not GCC;
> in this case, however, that file belongs to the linux kernel
> (linux/include/asm-i386/system.h).
>
> It still contains 'new' in the latest 2.4 and 2.5 kernel trees. You may
> wish to report it to them instead.
>
> I'm not well up enough on the C and C++ standards to know if this is
> really a problem - there may be ways that it's supposed to compile
> anyway, and it appears to have survived for some time.
>
> Rup.
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: Fw: /usr/include/asm/system.h
2002-05-21 12:37 Fw: /usr/include/asm/system.h Claude Lamy
@ 2002-05-21 12:48 ` Dave Jones
2002-05-21 16:51 ` Dave Jones
0 siblings, 1 reply; 3+ messages in thread
From: Dave Jones @ 2002-05-21 12:48 UTC (permalink / raw)
To: Claude Lamy; +Cc: linux-kernel
> > > I am running a Mandrake 8.1 linux distribution with gcc 2.96. In
> > > the file /usr/include/asm/system.h, the function __cmpxchg uses a
> > > parameter named "new" which is a reserved keyword in C++.
The function is wrapped in an #ifdef __KERNEL__
Kernel code isn't meant to be compiled with a c++ compiler
--
| Dave Jones. http://www.codemonkey.org.uk
| SuSE Labs
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: Fw: /usr/include/asm/system.h
2002-05-21 12:48 ` Dave Jones
@ 2002-05-21 16:51 ` Dave Jones
0 siblings, 0 replies; 3+ messages in thread
From: Dave Jones @ 2002-05-21 16:51 UTC (permalink / raw)
To: Claude Lamy, linux-kernel
On Tue, May 21, 2002 at 02:48:33PM +0200, Dave Jones wrote:
> > > > I am running a Mandrake 8.1 linux distribution with gcc 2.96. In
> > > > the file /usr/include/asm/system.h, the function __cmpxchg uses a
> > > > parameter named "new" which is a reserved keyword in C++.
> The function is wrapped in an #ifdef __KERNEL__
> Kernel code isn't meant to be compiled with a c++ compiler
I was of course, completely wrong about this, that #ifdef doesn't cover
the whole of <asm/system.h>.
Some of the stuff outside that ifdef will never work in a userspace
app anyway (like wbinvd). Looking at it, is there anything there at all
that we should let userspace be seeing, or should that #ifdef cover
the whole file ?
Dave.
--
| Dave Jones. http://www.codemonkey.org.uk
| SuSE Labs
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2002-05-21 16:51 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2002-05-21 12:37 Fw: /usr/include/asm/system.h Claude Lamy
2002-05-21 12:48 ` Dave Jones
2002-05-21 16:51 ` Dave Jones
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox