11 votes

Google introduces Carbon, an experimental replacement for C++

6 comments

  1. [4]
    Akir
    Link
    I’ve got zero excitement on this one. This article is weird: it seems to be full of marketing-speak and not a lot of concrete details as to how it’s actually supposed to be better. Unless I missed...

    I’ve got zero excitement on this one. This article is weird: it seems to be full of marketing-speak and not a lot of concrete details as to how it’s actually supposed to be better. Unless I missed something I only found three concrete improvements: generics, memory management, and a future built-in package manager (which is understandable but if you are trying to avoid software bloat, adding in a quick and easy way to add giant frameworks or micro-packages a la left-pad is probably not the best idea).

    Honestly this is kind of reminding me of the time Facebook got tired of how slow PHP was and invented their own faster implementation. Just like then, I doubt that Carbon will take away much of the C++ market. C++ is so big and important that practically every language could be considered a C++ replacement, and Carbon doesn’t make a better argument about why it’s a better solution than any of those other options. Or at least this article doesn’t.

    3 votes
    1. [3]
      stu2b50
      Link Parent
      It's not really fair to judge it from this random news article, wherein the technical details were regurgitated and embellished by a non-technical writer. Better to just read from the developers...

      It's not really fair to judge it from this random news article, wherein the technical details were regurgitated and embellished by a non-technical writer. Better to just read from the developers themselves: https://github.com/carbon-language/carbon-lang

      It makes sense a project. I doubt it will consume C++ entirely, but that's the point, it doesn't have to. It's trying to be the Typescript for C++, which is fine. C++ is well known as a language with terrible UX, from the godawfully primitive way to include dependencies, to

      "oh, so I make new heap allocations with the new keyword, right? No? I should use the appropriate smart pointer for the type ownership this heap object should have? ...ok, so I make a unique pointer--I can't make a unique pointer with its constructor? It can blow up? I should be using make_unique...?"

      On the other hand, languages like Rust are way more ambitions than something like Carbon. That makes sense, but it also means you need to do significant developer retraining before they're up to speed in Rust.

      With Carbon, you can selectively target critical C++ areas to replace since it's interoperable, you can use the same developers, and you can replace the orbital cannon aimed at your feet with merely a pistol aimed at your feet.

      12 votes
      1. [2]
        teaearlgraycold
        Link Parent
        Your comment is, interestingly, a much more measured response than I’ve heard from the inside of Google. But I only talk with the Rust people and they might just feel insecure about a new...

        Your comment is, interestingly, a much more measured response than I’ve heard from the inside of Google. But I only talk with the Rust people and they might just feel insecure about a new competitor language.

        3 votes
        1. skybrian
          Link Parent
          That seems pretty likely. When the GWT folks talked about Dart and the Dart folks talked about JavaScript, they weren't always measured either, in private. (In public, people are much more polite.)

          That seems pretty likely. When the GWT folks talked about Dart and the Dart folks talked about JavaScript, they weren't always measured either, in private. (In public, people are much more polite.)

          1 vote