Re: [PATCH] C++ breaks on linux/ioport.h

From: Khimenko Victor (
Date: Sat Apr 29 2000 - 04:44:11 EST

In <> Bill Huey ( wrote:

>> Yes I do believe that and yes I have written C++ code, I also learned
>> that everything that I found was exciting in C++ could be done just as
>> well in C.

> That's bullshit.

It's true :-) When you are doing things myself you can do this PORTABLE and
RELIABLE. When you are using VERY OPAQUE language you are essentually FORCED
to rely on PARTICULAR IMPLEMENTATION. Is it possible to choose where VMT will
be placed - in data segment common for class or in object so you can change
set of methods in run-time ? Oh, I forgot that you can not change set of
methods at all...

> Then you don't know C++ and have a very narrow scope in understanding
> modern programming language, parametric classes, class prototypes,
> OOP message passing over a network, etc...

You are joking, right ? GNOME has enough "class prototypes", "OOP message
passing over network" and other buzzthings. All in plain C.

>> up for C++ is going to cause a whole lot of problems.
>> Jes

> No more problems than assembler linkage layer in EGCS.

Hmm. This is not true. Lots of nice features of C++ need support from
run-time systems and using lots of space on stack. NOT what you want in
kernel where even gcc run-time was stripped out (kernel is NOT linked with
libgcc and it's done deliberately), where you have only 4-5KiB on stack
to play with and where heap is bonus (kmalloc, vmalloc and other things
exist but should not be used if not REALLY necessary). I'm not sure if C++
is needed even in userspace but in kernel space it's not appropriate.

P.S. Of course you are free to write kernel modules on anything: Pascal, Ada,
PERL, TCL, Java or C++ but it's YOUR problem to make thing compileable then.
C++ is no different here then PERL or Ada: kernel written on GNU C (not even
in C - there are enough GNU extensions like __inline__ used) and that's it.

To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to
Please read the FAQ at

This archive was generated by hypermail 2b29 : Sun Apr 30 2000 - 21:00:16 EST