Re: a great C++ book?

From: Richard Gooch (
Date: Tue Jan 01 2002 - 20:41:13 EST

J. A. Magallon writes:
> On 20020101 Richard Gooch wrote:
> >
> >Object-oriented programming is a good tool. One of many. But it
> >shouldn't be a religion, nor do you need to write in C++ to make use
> Use the right tool for the purpose. You bet for rewriting half the
> C++ runtime in C instead of not-using the bloated part of C++.
> Pretty. If you're going to program in a OO way, use an oo language.
> And I get tired of people saying C++ is bloat.

Actually, I didn't say that C++ is bloat. I said C++ makes "it much
easier to write bloatware". Big difference.

> My pupils at 5th course of Computer Science still think C++ is
> bloat.

Good. That means they'll approach it with caution, rather than jumping
on the bandwagon.

> They have no idea on compilers. And they bless Ada. A 5th level
> virtual function still has only a one-level indirection overhead
> when called. Low level code is just as efficient as C. If a C++
> program is bloated it is the programmers matter, not the language.

Not when the language seduces you into writing bloatware. The more
powerful the language and the more abstract the concepts it supports,
the further the programmer is taken away from understanding what's
happening at the low level. That leads to bloatware.

If I had my way, no CS student would graduate unless they understood
what's happening at the low level and had experience benchmarking and
optimising code. A good start would be to have at least one assignment
where they have to write a reasonably complex piece of code, in any
language, and their marks are based on how fast the code runs. And the
marks should be scaled down if everyone writes code which is much
slower than the instructor's.


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

This archive was generated by hypermail 2b29 : Mon Jan 07 2002 - 21:00:16 EST