Justin du Coeur (jducoeur) wrote,
Justin du Coeur

I think it's getting to be time to shoot C++ in the head...

This article on Lambda the Ultimate was the first I'd heard of the new C++ concept of "Concepts". Basically, C++ is starting to recognize that its version of generic programming, while powerful, is kind of brittle, and it's remarkably easy to get remarkably confused by the bugs that arise from it.

If you read through the above-linked article, though, it kind of hurts. They're introducing a whole new idea (rather complex idea at that) that is rather parallel to interfaces, but limited to a rather precise purpose. It offends me in rather the same way that Single-Use Kitchen Gadgets offend Alton Brown. You can get nice clean, predictable compile-time behaviour from your templates, by adding new ideas of Concepts and Concept Maps that make it all twice as complex.

Bjarne Stroustrup, the god of C++, has a decent article on why the current model is over-complex, and seems to have a better handle on reality. But really, the whole thing leaves a bad taste in my mouth. I mean, yes -- I recognized long ago that C++'s days were pretty numbered. But this feels like such a hack onto the side of the language, and the rationalizations feel so tortured, that it just drives home that the language is obsolete. They're trying to shoehorn in what amounts to Scala's Trait system, but treat it as a special case so that they don't have to deal with the broader ramifications of the idea. Whereas the same functionality in Scala is far cleaner and better-integrated into the language -- it just recognizes that, once you truly go down that road, you wind up with a very different language...
Tags: programming

  • Adtech

    Here's an interesting article about "adtech" -- those automated algorithms that companies like Google and Facebook use to spy on you and serve up…

  • Chrome instability?

    For the past week or two, Chrome has become surprisingly unstable -- it's been crashing on me about once a day. Weirdly, it is usually when I'm not…

  • Crossing the Uncanny Valley

    [Trying out posting from DreamWidth. Let's see if everything is configured right.] Just saw Rogue One. Capsule Summary: not an epic for the ages,…

  • Post a new comment


    Anonymous comments are disabled in this journal

    default userpic

    Your reply will be screened

    Your IP address will be recorded