C++ is for Camry

Occasionally Trini would ask me for programming tips, except they weren’t really programming tips in the first place, since obviously she knew the language better than I did. What she wanted to know from me, generally, was “Does this flow make any sense?” It’s possible to make things work — which, in some shops, means “Hey, it compiled!” — without those things actually working in the manner originally intended. We have code that seems to date back to Leonardo, and not the Renaissance man, but the badly-animated king; the best advice I could give her, generally, was “Read these, and then don’t do that.”

And don’t follow Toyota’s lead, either, Jerry Pournelle seems to be saying:

In the various [Niklaus] Wirth languages starting with Pascal the goal was to have the compiler catch incipient bugs: it took longer to develop a program that would compile, but once it did, it was likely to do what you expected it to do. Unfortunately the computer hardware of the time wasn’t up to huge programs in strongly typed and highly structured languages; it took a long time to compile a new addition to a program. The programming world turned to C and its derivatives, and in the early days a C compiler would compile almost anything, including very tricky uses of pointers and type changes.

I don’t know what language Toyota has used to develop its drive by wire programs, but I would bet reasonable sums that it wasn’t Ada or one of the Wirth languages.

The Director sums it up this way:

To make it easier for people to become developers, they made it easier to write software. To deleterious effect.

“It compiles,” she says, “but it still looks wrong.” Her instincts, I suspect, were sound indeed.

Share

 Tweet this

2 comments

  1. smitty »

    23 February 2010 · 6:12 pm

    If you ever read Stroustrup, he spends some time talking about “taste”.
    He also codes in a proportionally spaced font, which blows all both of my brain cells.

  2. unimpressed »

    23 February 2010 · 10:07 pm

    Part of writing good code (which I can’t) is also “elegance”. Way back when I wrote batch files, I used parameter passing to reduce the ‘garbage quotient’ thereby greatly reducing the amount of code necessary to get the job done.

RSS feed for comments on this post