r/cpp • • 21d ago

Maybe C++ would win if it adapted quicker?

I know that I'm oversimplifying here. The way the new C++ standard is released is pushing the language behind the others, especially those who adapt new language features quicker and favorize new modern language features.

I'm not saying that the movement towards modern C++ (whatever that might mean) is not helping. I love the fact that there are new exciting features such as reflection in the C++26 standard. Saying that however, even though the standard is supposed to have these features, the adaptibility by the compilers and the ecosystem is extremely slow.

Here we are in 2026 and MSVC as of now has zero C++26 core language features implemented. And god knows how long they will be unavailable. I feel like only now when its 2026, c++23 started to be slowly adopting, which I find sad. PS: I'm aware that GCC has mostly all features implemented, but STILL not all of them. Similar situation for Clang.

Maybe a more "aggressive" and faster release cycle would help? Also faster deprecation and language cleanup? The general push has always been towards backwards compatibility, but you can't always add new things that people want without breaking compatibility and removing deprecated features. And I think that for the language it's very important to adapt the modern programming language standards. But now I don't feel like that's happening.

Obviously there are other issues with C++, such as not having standardized package managers, linters, formatters, etc. For example, the clang-tidy formatter is abysmaly slow, and just painful to use, probably because it has to accomodate the million features the C++ language permits, and even the things that doesn't make sense no more and are just left in the language as obsolete things, ready to be removed after 20 years, which is hilarious.

Anyway, what are your thoughts on this topic?

EDIT: I agree that chosing the wording "win" is a bad wording here. The main point was to address some of the weaknesses C++ has compared to other languages/ecosystems.

0 Upvotes

44 comments sorted by

35

u/mr_seeker 21d ago

Win what ?

-10

u/Background-Error-910 21d ago

I didn't want to say directly, but let's say be more popular than is now when new people are choosing a language for a project and they're deciing between rust and C++, the choice is obvious for 9/10 projects.

15

u/renchuwang 21d ago

By your metric, C++ already won. Rust is only more popular than C++ if you are vibe coding.

0

u/Background-Error-910 21d ago

Even if you're not vibecoding, I'd rather pick Rust in 9/10 cases, because the expereience in both the language and the ecosystem is more pleasant IMO

8

u/renchuwang 21d ago

Thanks for your opinion. But you're asking about popularity.

Also ecosystem wise there is no comparison. Rust has good dev tools sure.

10

u/Rabbitical 21d ago

But rust doesn't solve all problems C++ does, certainly not faster and better. This isn't an argument against rust, but advocates for it being simply superior dismiss the upfront cost of quick prototyping, and/or the unsafe necessity in the end for certain things. To say you prefer rust 9/10 is a personal preference, not one based in reality in terms of what's actually used for what jobs. Again, I personally have a mountain of criticism for C++, and also respect rust for solving the problems it set out to, specifically. That does not mean it is simply better, that kind of a statement belies a lack of knowledge of the entire domain space and requirements therein that C/C++ currently occupies

3

u/alexeiz 19d ago

I heard an opinion that Rust is great if you never have to look at Rust code.

5

u/neppo95 21d ago

A language doesn’t have to be popular. You use the right language for the job. In a lot of cases that simply is not C++. But damn is it good where you do actually need it.

13

u/kitsnet 21d ago

Maybe a more "aggressive" and faster release cycle would help? Also faster deprecation and language cleanup?

How would that help those whose safety-certified compilers and tooling are still at C++17?

9

u/ConcertWrong3883 21d ago

17?? Lucky bastard!

2

u/StickyDeltaStrike 21d ago

The reality of C++ at work in some places lol

0

u/t_hunger 21d ago

The interesting thing is that other languages manage to keep certified compilers up to date with their latest uncertified compilers. In wonder what they do differently.

10

u/kitsnet 21d ago

Which "other languages"?

-2

u/Background-Error-910 21d ago

I mean there will always be slow adapters, but new language version should just bring new features in favor of not maintaining compatibility, so that the people when choosing a language for their new project'd still want to choose C++ because it has good features which at this point it lacks and the adaption is just slow in favour of compatibility. Which I feel like is not so common at this point.

5

u/kitsnet 21d ago

At the moment, C++ is mosty supported by projects that take years to implement and decades to maintain. If you want flashy new features for throwaway code, there are other languages for that.

19

u/Sinomsinom 21d ago

A "more aggressive and faster release cycle" for the language would only mean compilers would fall behind even more. 

"Faster deprecation and language cleanup" would only guarantee that even more companies refuse to update to newer versions of C++ (it's possible that this changes as more andore companies employ ML tools for codebase modernisation but I wouldn't count on it).

Are there modern features that most people agree C++ needs (e.g. pattern matching)? Yes definitely. But the problem with a language like C++ is that before they ship, there needs to be consensus between multiple sometimes opposed interest groups on how to actually add this feature. A quicker release cycle wouldn't speed this up. So if C++ e.g. now started doing yearly releases instead of releases every 3 years, it wouldn't actually mean more features get added to the standard or implemented into compilers. It would just mean that each version of the standard now has fewer features.

2

u/t_hunger 21d ago

I'd say fewer features per standard update would be a good thing though. It is much easier to adapt your codebase to small changes happening all the time than to one big bundle of changes every couple of years.

5

u/AKostur 21d ago

That could happen now.  The compilers frequently have flags to enable upcoming features.  So “they” could be adapting their codebase on those.

But: Upgrading the compiler isn’t free.

18

u/baudvine 21d ago

The three-year cycle is already much faster than it used to be, and as you can see compilers aren't keeping up (and neither is the standards committee, C++23 was finalized in '24). And *still* everyone's unhappy about the changes and modules never caught on.

I think C++ is unavoidably slow to change, and the fact that the vast majority of existing code out there continues to work is a big reason it's still used as much as it is.

6

u/Puzzled-Garage584 21d ago

faster releases won't help ... you go as fast as your slowest dependency(compiler/vendor libs/ binery deps/people) . with C++ you don't use the newest standard, you use the newest one ALL your stuff support

6

u/steveklabnik1 19d ago

Since Rust was mentioned in contrast here, I'll give my two cents. I don't like the "win" framing, but let's maybe talk about "how could C++ improve its development process?" in a more generic sense.

I don't think that simply making the cycle shorter is going to help C++ ship faster, as that's not the whole story with Rust. Let's compare the two systems:

C++:

  1. Committee designs a feature
  2. Committee accepts a feature
  3. Every three years, new standard is cut
  4. Implementation

Rust:

  1. Committee designs a feature
  2. Implementation
  3. Committee accepts a feature
  4. Every six weeks, a new release is cut

Yes, the release cadence does help. But the bigger thing is that nothing makes it into the language until after it's been implemented and tried in the wild. There is tons of stuff in Rust land that we designed, went forward with implementing, and then some issues came up that held up the eventual acceptance of that feature for years, sometimes even a decade.

The faster release cadence means that there is less pressure to accept a bad feature's design, as you only wait six weeks and not three years. But that isn't actually the largest driver of process, in my mind. The actual driver of process is that features come into contact with the real world before they become a permanent part of the language proper.

4

u/ventZl 20d ago

I'd say that the language is evolving at rather OK-ish pace. What specific are you missing in it?

Deprecation happens, just go check spec and you'll see there are (mostly STL) features being deprecated in pretty much every C++ version.

There's no reason to remove features just for sake of them being removed. C++ is multi-paradigm language, so unlike Java or C#, there's no one single canonic way to write C++. C++ is a toolbox and developer must choose tools suitable for his task. This supports C++'s versatility. You can't go bare metal (I mean really bare metal) with Java or C#.

Also, there are billions of lines of code written someone has to upgrade. Companies won't invest in upgrade if it has no benefits for them. Still, at least CppCon-led survey shows that many companies are at $current - 2 version and $current - 1 version (as of now C++20) has rapidly increasing adoption.

I'd say that situation is rather good and language is healthy for at least another 40 years of usage.

3

u/Sachu_James 21d ago

The compiler gap matters in practice because I cannot use a new feature until the compiler I actually build with supports it, so I end up writing to the older standard even when the new one looks nicer.

5

u/TheRealSmolt 21d ago edited 21d ago

When these kinds of opinions come out, they (in my opinion) usually fall into the same trap. C++ is a tool. A tool that excel at certain things, with a large and diverse user base that rely on those capabilities. It's not a contest; there is no winning or losing. C++ doesn't need to be, nor should it be, the answer to everything.

6

u/KindCppCoach 21d ago

One of the things is C++ can't 'standarize' a package system, the standard is about the language and standard library, tooling, hell, even the linker is not the standard. There is not some big tech company developing C++, its commitee driver and community supported. many of us are just professional volunteers. However , a standard package system could be contributed by anyone, the biggest problem is adoption and diversity, people in C++ have such diverse backgrounds, platforms, application that coming up with systems that would work for everyone, or even a majority is not a trivial task.

4

u/t_hunger 21d ago

Other languages can standardize tooling. C++ could do so, too, if they wanted to.

But of course we never standardized tooling (that was just not how you did it backnwhen C++ was new!), so there is inertia that would need to get overcome.

8

u/amoskovsky 21d ago

In most languages with praised tooling like Rust, Go, the tooling is just a convention governed by the project team, not a real standard that is independently ratified by an org like ISO.

Why do you demand an ISO standard for C++ tooling? What a double standard ))

You can have this convention with C++ too, and as a matter of fact there are several ones. Just pick one and use.

2

u/t_hunger 21d ago

Yeap, tooling is handled in the same way as the language itself by the same organisation.

-1

u/CornedBee 20d ago

Apples to apples - those languages you listed don't have any official standard for the language either. So saying that they don't have a standard for their tooling is not an argument why C++, a language with a standard, shouldn't have that.

1

u/amoskovsky 20d ago

Yes, apples to apples.

Good luck having an ISO consensus vote selecting one of several competing existing implementations.

2

u/AKostur 20d ago

Why wait?  If the community settles on a particular build system, then it should be easier to get it Standardized.  But that’s the rub: the community hasn’t.  Cmake tries, but there’s also the vocal group that says cmake is terrible,bazel is the way to go.  And the next group that feels bazel is magical incantations and Make is the way to go.  Repeat for every build system.

6

u/AKostur 21d ago

So you’ve already noted that a major compiler vendor isn’t up-to-date with the bleeding edge, yet you’re looking for the standard to move faster?  Why wouldn’t that just make things worse?

4

u/pjmlp 21d ago

That won't help anything, as the main reason compilers lag behind and have been reduced to only three major compilers is lack of funding, and a standard that is designed without any regard for compiler vendors, as it stands today.

The standard gets ratified, not all of the features even had any kind of preview implementation, WG21 moves on into the next standard, and up to compiler vendors to implement it, assuming they actually care.

Which has become a bigger problem as most companies that sponsor LLVM development, care about it as compiler development infrastructure, and very less so about clang.

Thanks to clang's existence, GCC contributions nowadays are mostly from companies that are at ease with GPL.

MSVC, well Microsoft seems to nowadays have other places where their rather spend their budgets, and the standard release cadence won't change that.

Finally you have the volunteers that can only contribute so much, regardless of what comes out from WG21.

3

u/Sarduinot 21d ago

I don’t think MSVC cares much. I mean the people on the team probably care, but the people allocating resources to MSVC have stopped caring.

Thats not something they would say to the team. Even if you’re gonna downsize a team, you don’t want to prematurely demoralize them. But you might not give them enough time to implement the new C++ standard.

3

u/Thesorus 21d ago

C++ will always be behind newer languages in terms of features adoptions.

C++ has such a large legacy code base all over the place and it needs to be backward compatible.

This means new language features have to be coerced in the existing language.

3

u/t_hunger 21d ago

To be fair: We do not know yet what exactly will be in C++26, considering that the draft got rejected. Some things will change, nobody knows what exactly yet AFAICT.

If I worked on compilers I would not touch anything C++ before it is fully ratified after this experience.

5

u/pjmlp 21d ago

In the last century, it was implementation first, existing practices, afterwards, looking at how programming languages standardised by ISO used to be.

Features had to prove themselves first, land into the standard afterwards.

1

u/chilabot 21d ago

Some programs need to get redone in order to add more functionality. Same happens with some programming languages.

0

u/UndefinedDefined 21d ago

Maybe only accepting what was already demonstrated in one compiler and working, and after it got feedback from users.

Modules was a huge fiasco, because there was no implementation and it required a lot of tooling changes to work as it was standardized. I think if the requirement was to have it working before any vote - there wouldn't be modules in C++20.

Maybe we could have a standard package manager instead of modules if all the effort put into modules was put into making C++ simple to use when you need dependencies (which you always do regardless of what you do).

2

u/pjmlp 19d ago

Actually modules had two implementations, and a third design that did not match either.

It had clang header maps implementation, used to this day by Apple and Google, and the main way how modules are used in Apple ecosystem between Swift, Objective-C alongside C and C++ language interop.

It had the Visual Studio 2017 modules prototype, which was used for the C++20 modules initial proposal.

And then what was standardised was something else.

Also we have the ironic situation that even though Visual Studio 2017 modules prototype was used for the initial proposal, two Visual Studio releases later, and Intelisense still doesn't work properly with modules, because Microsoft did not consider having some deal in place with EDG to fix it.

1

u/UndefinedDefined 18d ago

It's great, but if the standardized approach diverged from implementations then I guess what you said doesn't counter-argument what I said.

1

u/pjmlp 18d ago

That is the whole point, it should not diverge, standardisation of existing practices, or common language extensions has to be the driving force.

-1

u/Nothing_from_void 21d ago

I mean hot take, but people who use C++ most heavily don't care about these new features. They mostly just want C with classes, templates, and maybe a standard library that doesn't suck but they may prefer to design their own data structures. Just look at the places where C++ is holding strong; game dev, low level AI libraries, low latency trading/networking, they mostly care about staying close to the metal not adding fancier abstractions