Messages in this thread | | | Date | Wed, 07 Jul 1999 00:11:53 +1000 | From | Dancer <> | Subject | Re: linux headers and C++ |
| |
Jes Sorensen wrote: > > >>>>> "Jamie" == Jamie Lokier <lkd@tantalophile.demon.co.uk> writes: > > Jamie> Albert D. Cahalan wrote: > >> Linux already uses more than a C compiler offers. The best answer > >> would be to merge gcc and g++, using a config file to enable the > >> features that Linus approves of. Linux could use "C+" then. > > Jamie> One of the reasons Linus stopped using g++ on the kernel was > Jamie> the quality of the generated code. I gather g++ generates much > Jamie> better code now. > > Jamie> It'd still be important to disable exceptions (for example). > Jamie> And templates remain dangerous bloat-generating territory. > > And templates, and operator overloading etc etc. > > C++ is much harder to maintain because there are a zillion obscure > features people can use in there. It means that the people who > maintains the kernel needs to understand these things as well thus we > suddenly reduce the number of potential kernel programmers to a tiny > fraction of what we had before.
I do a lot of stuff that involves attaching C++ code to C code. Really, it's the C++ coder's responsibility to insulate other subsystems, if they're bolting C++ onto a C framework. Likewise, when a C programmer is bolting C code onto C++, it's his responsibility to ensure that the C++ base is unaffected.
I've seen C++ code that plugs into the kernel (it was a driver module, in fact). No changes to the kernel required, just a little care from the C++ coder.
So...why are you guys fighting? Is it just on principle, or is there some valid objection that hasn't been raised yet?
D
- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.rutgers.edu Please read the FAQ at http://www.tux.org/lkml/
| |