• HaraldvonBlauzahn@feddit.orgOP
    link
    fedilink
    arrow-up
    28
    ·
    edit-2
    9 days ago

    This is a sign that C++ is (still) struggling with its governance (see a previous article on cultural issues within C++ here). This is a big deal even if you do not care about programming languages. C++ is arguably the most important programming language in existence.

    Your computer runs on C or C++. The web browser you are using to read this is written in C++. ~All programming languages depend on C++ (often through LLVM). Likewise, ~all websites with performance requirements (e.g. YouTube) depend on C++, ~all data storage, game engines, finance, etc.

    In a world that is drowning in exciting new vulnerabilities in ~all software, the ability of C++ to change and adjust to changing times affects you.

    [ …]

    Why are Contracts authors so obsessed with getting Contracts into C++26? Why not wait for the next release?

    Well, C++ has this funny “release train model” (also known as “the frame rule bus stop analogy” in Super Mario Bros. speedrunning). A new version of the C++ standard releases every three years. If your work gets voted into the standard in time, it becomes part of it. If it doesn’t, you have to wait another three years for the next release.

    Three years is a long time, and it’s an especially long time to work on a single C++ feature. Getting a C++ paper accepted into the standard is a process so notoriously draining that ~all of the “C++ people” I know just stopped bothering, and stopped working with WG21. It’s bad.

    If Contracts don’t get in this cycle, there’s a good chance they never will. They will be nitpicked over the next three years, endlessly litigated, and frankly, I think there’s a good chance several of the people working on Contracts just won’t want to deal with that, and might instead drop out of the process entirely, leaving Contracts dead and buried.

  • thingsiplay@lemmy.ml
    link
    fedilink
    arrow-up
    7
    ·
    9 days ago

    This would not happened with Rust.

    /s

    Off course this is a joke reply. Because with Rust it could not be a C++ Standard.

  • xxce2AAb@feddit.dk
    link
    fedilink
    arrow-up
    7
    ·
    9 days ago

    Maybe if that had happened sooner, we wouldn’t have ended up with a barking mad mess.

    • lemmybeyourfwend@lemmy.org
      link
      fedilink
      arrow-up
      1
      ·
      6 days ago

      Difficult to erase entire products and projects built around C++ from one day to another. Yes, Rust is awesome and so is C++, they both have a place in this world 🤗

    • thingsiplay@lemmy.ml
      link
      fedilink
      arrow-up
      6
      ·
      9 days ago

      There are more experts and code in C++ than Rust. The entire world runs in C and C++. So working on those languages and expanding or refining them makes sense. Even if Rust takes over the world and is more used than C++ in the future (if that happens ever), it would still make to maintain and refine the language. Not everyone likes or wants to use Rust.

    • BeigeAgenda@lemmy.ca
      link
      fedilink
      arrow-up
      5
      ·
      9 days ago

      Even if we include LLMs porting code, the sheer amount of c++ code makes it not worth porting, and some legacy code just need occasional updates, especially embedded.

      I expect that even if porting becomes free, perfect and instantaneous, there will be plenty old c/c++ code around for decades.

      • HaraldvonBlauzahn@feddit.orgOP
        link
        fedilink
        arrow-up
        4
        ·
        edit-2
        9 days ago

        Even if we include LLMs porting code, the sheer amount of c++ code makes it not worth porting, and some legacy code just need occasional updates, especially embedded.

        It is more effective not to port old working code, which would cost a lot of resources, but to write new code in Rust, where this is possible. There have been a few studies on this, even from companies like Google. The thing is that new code is more likely to have bugs than working old code. So, spending effort on new code gives more safety for a given amount of effort and resources.

        On the other hand, it absolutely makes sense to write completely new projects in Rust, if the needed library support is there, since Rust tends to be more productive.

        Also, in embedded systems, space systems, systems with certification requirements and so on, Rust is making inroads. Though these are rather conservative areas where tools are not changed quickly.