r/cpp • • 11h ago

[ Removed by moderator ]

/r/cpp/comments/1y9x3pm/removed_by_moderator/

[removed] — view removed post

87 Upvotes

169 comments sorted by

•

u/cpp-ModTeam 2h ago

AI-generated posts and comments are not allowed in this subreddit.

→ More replies (1)

87

u/Expert-Map-1126 vcpkg maintainer BillyONeal 9h ago

I joined MS because I saw u/STL giving talks about the STL, back when the only way to get single exe xcopy deployment was important for my use cases forcing C++. I got my dream job working on that team and I think I shipped good work there. But after seeing what happened to standard networking[1], I poured a good chunk of my career into vcpkg because I agree that this library/interop situation *NEEDS* to have a solution people can depend on.

The problem is that vcpkg / conan / etc. can't fix the core of what makes cargo/npm/et al. successful in C++. Cargo works because people *expect* to ship with cargo, have accepted its limitations, and component authors in general try to follow the rules that make it work. For instance, in order to deal with the dependency situation in C++, people like to vendor copies of their dependencies. Which is great, but falls over as soon as 2 people do that as they now break the ODR. In cargo, you would have the same situation -- but people don't tend to do that when just adding a cargo package dependency is easier. Successful package management is *entirely about* having an ecosystem that works when "what if 2 people do this" happens.

The unfortunate reality that I've come to accept is that the C and C++ ecosystem writ large won't accept this for some reason. Every package manager, be they apt, dnf, vcpkg, etc., has to maintain piles of patches in order to keep components playing nicely with each other. And we do that because component authors don't *want* to force lock in on their users into a particular package management ecosystem. And there are good reasons for that; for instance cargo or vcpkg would be awful for end user application deployment (which is one of the reasons we bend over backwards to avoid competing with apt et al. in that space).

Deciding to work together in that way as an ecosystem is not something the language, WG21, or any individual package management solution can do for us.

[1]: That is, I believe there will never be standard networking because all responsible networking needs TLS these days, and no TLS implementation will meet std:: ABI requirements

13

u/VinnieFalco wg21.org | corosio.org 4h ago

vcpkg is a beautiful program and it was the first time I had a good experience installing OpenSSL onto my Windows system.

•

u/UndefFox 3h ago

Wonder how much of the mix in the comments can be explained by Winslop vs Linux experience... like, so far didn't have any troubles with installing any packages for my projects simply because you just write pacman -S <the package> and simply add find_package to CMakeLists.txt of the project. But when I need to do some dev work on Winslop... I can definitely agree that getting stuff there was quite the pain. Partly because Winslop search sucks/

•

u/steveklabnik1 3h ago

Only dropping this in here since a lot of the OP is about Cargo: Cargo and the Rust ecosystem generally work well on Windows. At a previous job, the CTO, who is a huge UNIX (not even Linux) guy, was really surprised when I (a windows user at the time) showed up and was able to run virtually all of his stuff with no changes. (One script had some line ending stuff I had to write a ~10 LOC patch for.)

•

u/UndefFox 2h ago

Wonder what prevented C++ from doing so besides stuff not really being made cross platform simple since before it was quite the pain in the ass to get it to be cross platform/ I would assume Rust just goes the road of: cross platform > performance, while C++ goes performance > what you don't use.

•

u/steveklabnik1 1h ago

I don't think it's as simple as "cross platform > performance" vs the other. I suspect this has to do more with the build system and other tooling itself than the code, as C++'s standard library is also cross-platform. That said, maybe it's the case that a lot of codebases are more willing to reach into platform-specific APIs, and so it's just a cultural issue.

•

u/VinnieFalco wg21.org | corosio.org 2h ago

What do we need in C++, in order to have the same ease of use that cargo offers for assembling an application out of composable libraries?

•

u/steveklabnik1 57m ago

I think it's really about agreement.

Heck, I don't personally even use Cargo anymore, but even then, crates.io is the default package host for everyone, and even people that don't use Cargo push up cargo-compatible packaging, then map that back to their packaging system. (buck, in my case.)

Getting everyone to agree on one thing seems very, very difficult.

There are some more minor things:

  • Rust has a culture of building from source, C++ is much more comfortable with binary deps (cue pjmlp...)
  • Rust lets you have multiple versions of a package in a single dependency graph. This makes it easier to successfully come up with a resolution to all required dependencies. This is a nice thing, not a true blocker, exactly, but it would cause a lot of pain to get everyone onto one system.
  • Rust has a more unified confirmation scheme that everyone uses

Basically just way more agreement upon a way to do various things, so that it's all interoperable. The existing C++ things mostly try to be a superset and paste over all of the ways that downstreams want to do various things, whereas in Rust, downstreams all support the unified thing.

•

u/UndefFox 39m ago

Would this possibly cause issues to anyone else but devs that are very opinionated about the way things are done? Like, I usually very strict about the phylosohy of the design I'm going for. One of the things that stops me from using Rust is lack of partial borrow when calling methods that was proposed years ago, yet nowhere to be seen/ For me it is a big deal. Yet, I've checked a game engine written in Rust and it's way of doing it and... yeah, as expected 7 parameters and copy paste. Hence the question: are people really that opinionated, or Rust is just a niche that consists of people who agree with this design phylosohy? Because, I bet there will be a lot of possible friction in a language that is very opinionated in it's design and customs so to say.

10

u/jayeshbadwaik 7h ago

Hey Billy. Appreciate all your work.

What's the reason behind vcpkg, instead of for example pigging back onto existing ecosystem at the time, like conan for example?

15

u/Minimonium 6h ago

I can provide my perspective as I was more active at the time.

Back then Conan and Vcpkg had massively different approaches. Still different, but I would argue that Vcpkg moved closer to Conan's with time. :)

Vcpkg was built to be reliable and simple first - dead simple installation and usage for very specific case, no binary management, no complicated graph and build tool shenanigans, no full rewriting of upstream packages build files - anything CMake was adopted as native CMake. This loose design also allowed easier integration with system dependencies later.

Conan v1 was really ambitious as it wanted to do everything, but because of that it kinda did it rather poorly. With Conan V2 it became much better and a solid tool today although still suffers from the same ecosystem problems. It gave a DSL for companies to leverage it for their use cases rather efficiently (it was a win for us for sure at the time!).

•

u/Expert-Map-1126 vcpkg maintainer BillyONeal 8m ago

I would argue that Conan moved closer to vcpkg :)

The main philosophical difference between Conan (last time I looked very closely at it was admittedly 1.x) and vcpkg IMO is that conan exposed its own build system bindings mechanism. That's good in that you could use a component in conan and have some confidence that it would work, and the constraints imposed by that enabled somewhat more binary reuse than vcpkg achieves. The downside is that it shuts the door on composition with other packaging ecosystems; vcpkg tries very hard to avoid exposing our own custom bits to build systems so you can write one CMakeLists.txt or similar that works with us, or apt, or dnf, because "I build my Windows bits with vcpkg and get my dependencies from system package managers like apt/homebrew/dnf et al. on other systems" is a very common scenario.

I *think* Conan 2.x moves closer to vcpkg on this but it's been a long time since I've tried to do serious competitive analysis because it's been a long time since we've done serious feature work in vcpkg. We're kinda just keeping the lights on with the registry, but arguably the registry is the real value in the product.

9

u/tyler1128 9h ago

My current pet project is a C++26 (-ffreestanding) UEFI + NASM x86_64 hybrid thing. Ironically UEFI is forcing lock in, but that's not really my point. The more choices you make for a user, the harder it is to have escape hatches to those choices consistent with the language.

The NASM part is easy: -g -f win64. The 20 flags, and trying to figure out what that is supposed to be freestanding vs actually is is usually a very large difference. Yet I can use language features like contracts in Ring 0 with no operating system.

6

u/Expert-Map-1126 vcpkg maintainer BillyONeal 8h ago

The scenario you're describing here doesn't really have downstream dependents so it really isn't engaging with what makes a composable ecosystem work.

4

u/tyler1128 8h ago

How'd you package a library for such a system? There are plenty of them from boot-loaders to firmware that are highly within the domain C++ tries to be within. All of those systems have highly different requirements, a single package standard probably is not going to succeed on all of them.

•

u/Expert-Map-1126 vcpkg maintainer BillyONeal 12m ago

And yet... we are seeing rust / cargo packages succeed in those environments. There is no special magic needed for "here is some source code and this is how we will agree to communicate how to get my headers and libs". I'm not saying that literally everything necessarily needs to be supported by such a thing but I have heard many Many people tell me "cargo is the best thing about Rust".

I don't know how to get there from here. I'll be the first to admit, one of my favorite standard library features, iterator debugging, is somewhat incompatible with a truly packaged / componentized world.

•

u/tyler1128 6m ago

C++ has been improving on the "freestanding" front (core in Rust language), at least spec-wise. UEFI protocols are written to be consumed by C, but there is no reason not to have anything in C++ that doesn't require dynamic allocation, throw, or that explicitly requires an allocator to be passed to be available, imo. Though the CRT has a lot of globals that need setup and you'd be surprised how many C++ still depends on. ELF has a whole section table for (things that need to be run before main).

1

u/fortsnek274 4h ago

and no TLS implementation will meet std:: ABI requirements

How so? That some encryption methods would be removed? Wouldn't that just be a runtime error? Or API issues that need to be patched?

•

u/Expert-Map-1126 vcpkg maintainer BillyONeal 3m ago

Not API, ABI. OpenSSL, the defacto TLS implementation on Linux, has broken their ABI (and also API) at least 3 times (1.0.2x -> 1.1.0x->1.1.1x -> 3.0.N) since I started working on vcpkg; the standard libraries have not. A C++ standard library feature that can't be delivered by libstdc++ is a dead feature.

•

u/kronicum 2h ago

TLS implementations might move faster than WG21 moves or is willing to break ABI. In this day and age, where security and encryption are premium, no platform wants to be in the headlight spot for breaches.

•

u/fortsnek274 2h ago

There's certainly the idea that the rate C++ moves is too slow anyway.

And I can certainly believe that implementers and the standard would worry about getting it right first time. That's not a problem specific to networking.

•

u/kronicum 2h ago

It is not a problem specific to networking, but those were arguments for the failure of networking interface in the standard library.

If your observation is that WG21 should apply the same reasoning consistently in all its decisions, a lot of people will afree with you :)

-9

u/pjmlp 9h ago

Well to this day, vcpkg developers still don't care about the developer experience of their users.

It keeps targeting cmake users, with the Visual Studio and VSCode integration being quite far from what it could be.

One doesn't even have too think too hard about it, it suffices to match NuGET experience for C++ libraries, instead of a mix of command line invocations of vcpkg, and trying to convince Visual Studio of the vcpkg manifests presence, without any kind of nice IDE tooling experience.

The tickets are out there,

https://github.com/microsoft/vcpkg/discussions/40127

https://github.com/microsoft/vcpkg/discussions/35404

Yet I guess those of us that would like such improvements are a minority to warrant any development resources.

33

u/Expert-Map-1126 vcpkg maintainer BillyONeal 9h ago

Yes, I "don't care" about what I've dedicated the last 6 years of my life to.

...

Maybe don't go assuming what people care about.

35404 and 40127 are an ask for the vcpkg team to be about 3 times the size it ever was, minimum. Would I like it? Sure, but I can't get someone willing to fund doing it. And I don't believe it would really move the needle here, because cargo et al. don't have those kind of Visual Studio GUIs either. I have never had a customer tell me "I would use vcpkg but for missing Visual Studio GUI".

-9

u/pjmlp 9h ago

The competition does care,

https://www.jetbrains.com/help/clion/package-management.html#switch-manifest

Maven, Gradle, NuGET have such UI integrations.

As for cargo,

https://www.jetbrains.com/help/rust/create-new-rust-project.html

Well, I as a paying customer to Microsoft licenses see a 4 trillion valued company, that doesn't want to staff vcpkg team better.

Anyway, thanks for the reply, it is clear I and others with similar background are on the minority, and those tickets can be closed.

22

u/Expert-Map-1126 vcpkg maintainer BillyONeal 8h ago

I can't make a statement about whether you are in the minority and I'm not going to close a discussion about something I would like to see myself. It just isn't something the vcpkg team as it currently exists is likely to be able to deliver for you. If you're really a paying VS customer submit feature requests to Developer Community and maybe if enough customers do that the folks who own IDE bits might be able to look.

-3

u/pjmlp 5h ago

Yes, we have professional licenses.

•

u/Expert-Map-1126 vcpkg maintainer BillyONeal 5m ago

I can cite this to Visual Studio people but given that they're being squeezed by AI stuff right now I doubt it'll get much traction.

26

u/Minimonium 7h ago

Being toxic to underfunded maintainers like this is not helpful

•

u/Expert-Map-1126 vcpkg maintainer BillyONeal 5m ago

I am not personally underfunded, I'm quite happy with my compensation. I think vcpkg is underfunded though.

1

u/pjmlp 5h ago

Microsoft is not a garage shop struggling to make a buck.

If I am toxic, is for the company that asks at least $1,200 per year, discounting bundle deals, and the actual value for money.

11

u/eteran 5h ago

Are you under the impression that Microsoft is a monolith where every team gets the same amount of funding and that every team is equally responsible for all product decisions?

Seems like a weird take.

0

u/sweetno 4h ago

They don't pay for every team though.

•

u/eteran 2h ago edited 36m ago

That's kinda my point... They don't pay for every team, and each team is independent.

Yet they're complaining to the team which gives something away for FREE and justifying it because OTHER Microsoft products cost money...

•

u/pjmlp 2h ago

It is a customer take that pays for a specific product, and expects the commercial vendor, makes paying for such licenses attractive beyond an upgrade mill to get the latest .NET and C++ features, tied to specific Visual Studio versions.

A company valued in 4 trillion dollar.

-3

u/lone_wolf_akela 7h ago

Now that I think about it, maybe its time to vibe code a somewhat working vcpkg GUI plugin for VS 2026. Should not take many tokens...

1

u/tyler1128 8h ago

Maybe not everyone only uses Visual Studio and/or VSCode? The assumption behind that might be something to reflect on why the state of things are why they are.

117

u/tandycake 8h ago

I'm not anti-AI, but the heavy-handed use of AI on articles have made them unreadable. It's not for human consumption.

I read through this article the best I could. It's like walking through wet mud at your knees. I feel like you now need an AI to summarize these AI articles for you lol.

31

u/feverzsj 7h ago

That's just typical C++ Alliance output.

•

u/ScientistStrict9850 3h ago

Same, I clocked it in almost immediately. After working with agents for so long and contrasting it with working with people, there's definitely a very strong unique english(s) dialect that LLMs have. It sucks, i hate it.

It could be improved if the author went through and deleted lines that doesn't really contribute much to the flow of the article. Even asking the AI to rewrite paragraphs following some desired criterias can reduce icky LLMisms.

Despite so much coding demonstrations by companies and vibecoders, they still fucking suck at writing even as simple as an article that people wanna read. The topic is interesting, but the writing makes me want to ask a chatbot to read it for me instead.

•

u/Blissextus 1h ago

Unsurprisingly, my Copilot AI summarized his C++ criticism is with:

  • Web backends
  • AI application platforms
  • Cloud services
  • Modern developer tooling
  • Network-heavy applications

The article is less "C++ is dying" and more:

"C++ still has tremendous strengths, but the ecosystem around modern application development is lagging badly, and the community may be focusing on the wrong priorities."

3

u/James20k P2005R0 6h ago

I thought this one wasn't super LLM-y personally, but I am also remarkably bad as an LLM detector. I thought it largely made sense on my end

9

u/friedkeenan 5h ago

I don't know precisely the extent to which LLMs were involved in writing this blogpost, but it definitely did feel while reading it like it had some sort of LLM quality to it. Not to the point where it's screaming out that there's LLM output (though I'm not as good at clocking newer models' voices), but particularly in the metaphors that the blogpost draws it felt very LLM-y.

It also felt very ruminating and kind of circulating in a way that LLM output often appears to me, the rhythm of it feels quite a lot like what an LLM would accomplish.

And, well, it is also hard to ignore the "My Very Best AI Slop" at the top of the page, and the AI-generated cover image for the blogpost, and that he apparently gives a writing credit to Claude at the bottom of a previous post, though I don't care to read it and see if he's just joking, and his LLM-written proposals.

•

u/James20k P2005R0 2h ago

Yeah I'm just genuinely terrible at recognising AI generated text unless its word spaghetti - turns out I was incorrect about giving it the benefit of the doubt - entirely my fault

•

u/VinnieFalco wg21.org | corosio.org 3h ago

To be fair, you aren't wrong. My blog is where I don't invest in any polishing or editing. It represents "the state of the art" for machine-authored prose. I have switched to Gemini from Claude, because Gemini is a much better writer so far. I should probably put model labels onto the posts from now on so we can see the difference in the models.

These models are only getting better and in another year I think they will be very good at helping someone express their ideas quickly and succinctly. My position is that we need to spend time using them in practical settings so we can figure out how best to harness it.

•

u/t_hunger 3h ago

I would strongly prefer if you just put up the prompt itself instead. The prompt contains all the relevant data and would spare me going through a ton of generated fluff.

•

u/AhaGames 3h ago

Perhaps a ts;dr (too slop; didn't read)

•

u/VinnieFalco wg21.org | corosio.org 3h ago

LOL.. stealing..

•

u/VinnieFalco wg21.org | corosio.org 2h ago

I posted the prompt, but u/James20k deleted the original post and re-iterated the subreddit rules. As my posted prompt was also AI-generated, I have deleted it.

•

u/James20k P2005R0 2h ago edited 2h ago

Thanks for letting me know, AI generated prose is against the rules on the subreddit (although I appreciate you did not post it, I'm not warning you to be clear). Its generated some discussion on one hand, but judging by the prompt its nearly fully AI content

Getting stuff like this past me is like limboing under a crane, so given that people are finding this unreadable due to the AI usage, I think this is not necessarily ideal to leave up

Edit:

Reworded to be clearer sorry

•

u/VinnieFalco wg21.org | corosio.org 2h ago

Did "My Very Best AI Slop" placed prominently at the top of every page not give it away?

•

u/James20k P2005R0 2h ago

Given that I'm a mod here now I try and lean very on the side of caution when it comes to accusations of LLM generated text, and I do have just about the worst LLM detector as a person. I did very much laugh at that quote though, though I thought it might just be a joke personally!

•

u/VinnieFalco wg21.org | corosio.org 2h ago

Its both a joke and a disclosure. I know that the r/cpp rules list "NO AI CONTENT" as the first item, but consider what happened here. There was a productive discussion on an important topic which is now defaced by a moderation action. I personally am not invested (I did not post it) but I do think this reflects poorly on the subreddit. I think its time to revisit the policy.

•

u/James20k P2005R0 1h ago

Its not super ideal, but I do think this simply comes down to me messing up and approving this despite a couple of reports earlier, because I should have checked more thoroughly (and taken the quote more literally)

There's a tricky choice between leaving these up, or removing them, but now that people have realised its LLM generated the useful discussion has been derailed by this turning into complaining about AI generated content as the top comments/lots of the thread discussion

I'm also extremely wary that this post being left up would generate you more flak, for something that you didn't post and that you've not tried to hide as being AI generated content, given that its AI generated content on a not-AI subreddit

Either way this shouldn't happen again

•

u/VinnieFalco wg21.org | corosio.org 1h ago

That may all be true, but look at what happened. There was a productive discussion. Is that not the point of the subreddit? If the moderators take the position that AI content is bad, the downstream consequence will be people complaining about it, whether or not it creates a productive dialogue.

So now the subreddit has the awkward artifact of a good conversation, with a removed original post. I do think this suggests that the position towards machine-assisted content could be more nuanced. Why not instead say "No complaining about AI CONTENT" plus "We reserve the right to remove AI SLOP?" Or some kind of variation on this.

•

u/James20k P2005R0 1h ago

Why not instead say "No complaining about AI CONTENT"

The problem is that people generally complain about AI content because they find it hard to read (currently: the massively upvoted top comment and this comment chain), so I don't think removing complaints about AI content is the way to go personally. The complaints are a symptom of the fact that its not good content for them, so that'd just be hiding the problem

The main issue with allowing any AI generated content is that it immediately turns into a disaster. I also suspect if hypothetically we took a vote here, people would largely be against it - there doesn't appear to be much of a strong pro AI voice in these parts

(Bear in mind that I'm new to moderating the sub and would not be changing the rules one way or another, so I am also the wrong person to take this up with one way or another - this is my personal opinion on how I interpret the sub rules but I in no way speak for the mod team here)

There was a productive discussion. Is that not the point of the subreddit?

This is the big problem with how things have gone down, if I'd removed it immediately this would not have happened, which is my fault. Personally I've taken this down after weighing it for a while despite the current discussion, because the comments are starting to steamroll into an AI/you/C++ alliance hate train, which is now likely going to end up derailing future discussion in this specific thread, after people have clocked that its LLM generated

I can understand the perspective that if we discard everything - there's intrinsic value in an AI generated article that promotes discussion - I can see where you're coming from with that. I think the issue comes in in that for a significant chunk of people it starts to lower the signal to noise ratio for what they're looking for, so its borrowing against the future of the sub to get more engagement now

I'd rather personally that we have slightly less discussion now, but people generally come back to the sub because what they see is the kind of content they're looking for

→ More replies

•

u/mfukar 3h ago

It represents "the state of the art" for machine-authored prose.

just keeping this here.

4

u/[deleted] 5h ago

[removed] — view removed comment

•

u/cpp-ModTeam 1h ago

AI-generated posts and comments are not allowed in this subreddit.

35

u/eliminate1337 9h ago

If C++ dies it will be because a few dinosaur companies refuse to update their source code once a fucking decade. We sacrificed the language and ecosystem at the altar of backwards compatibility.

39

u/Leifbron 10h ago

Impossible without making another language

or at least a breaking change that ruins backwards compatibility

21

u/EC36339 10h ago

C++ is the worst language, except for all those others that have been tried from time to time.

17

u/simonask_ 8h ago

I think we can very clearly say that this is just not the case. There are still niches where C++ is the best choice, but they are shrinking, fast.

1

u/javascript 4h ago

Do you find the interop strategy for Carbon compelling?

-14

u/El_RoviSoft 10h ago

I think new language that will be extremely similar to C++ (not Rust) and be 100% compatible is the right choice. At least AI is very useful to design stuff like and make it compliant with original.

33

u/TomKavees 10h ago

The problem with that "100% compatibility" is that it would carry over current cruft that holds C++ back, negating the benefits of the migration.

6

u/Awkward_Bed_956 10h ago

Pretty much, its not that C++ had bad ideas and implementations all the time, but rather we had to adapt ourself to preserve the holy grail of 'we are the best language for C compatibility!',
new languages are interesting because they have have interesting ideas they can implement because they don't have burden

Also how do you design a '100% compatible' language to C++, where C++ doesn't have a stable ABI, there are different implementations of standard libraries, and compilers don't always agree how to do things?

This would be a horror beyond human comprehension that would make Lovecraft jealous

6

u/eliminate1337 9h ago

C compatibility isn’t the problem. C is a small and simple language. Rust has very good C integration as well. The problem is backwards compatibility with old C++.

3

u/Awkward_Bed_956 8h ago

Rust having good C integration means nothing, any language that doesn't have it is dead on arrival.

If C is so small and simple, why is building a parser for it borderline impossible, to the point everyone just existing C/C++ compiler to do it? And pretty much every language who wants to work with it just hardcodes all the integer types, not to mention the mess that is intmax_t.

C and C++ conquered the world, and they are used everywhere, they evolved and transcended from just being a programming language into a universal protocol of communication between languages, so they don't get to change that much anymore or things everywhere would break in horrible ways

3

u/pjmlp 9h ago

C is a small and simple language.

Only if you ignore everything past C89, and compiler extensions.

1

u/HommeMusical 8h ago

C is a small and simple language.

The C specification is almost 700 pages and costs $373 to buy. The Lua specification is by contrast 100 pages, and free.

0

u/tyler1128 8h ago

Rust also has two standard libraries. Std and core. One is basically but not completely a subset of the other.

The Rust edition system is novel and, while increasing compiler burden, does somewhat give the best of both worlds.

8

u/simonask_ 7h ago

What in the world do you mean? Rust's std is absolutely a strict superset of core.

-2

u/tyler1128 7h ago

I'm talking about the assumptions made and whether any given program targeting core can be made to target std with zero other changes (it can't). Rust is a good example of how to do it, though, unlike freestanding C++, which to be fair is relatively new in being formalized.

5

u/simonask_ 5h ago

Again, what the heck are you talking about?

Any #[no_std] library or executable can completely trivially be changed to use std. The core module is 100% available - you don't even need to change the name in your imports to use std instead. Same goes for the alloc module, since std == core + alloc and a few more small things.

-1

u/tyler1128 5h ago

So there are some assumptions that are different...

→ More replies

-1

u/lightmatter501 4h ago

And nobody can actually agree on what the cruft is.

10

u/HommeMusical 8h ago

I think new language that will be extremely similar to C++ (not Rust) and be 100% compatible is the right choice.

So what would be the difference between your C++++ and regular C++?

What do you have against Rust? I have decades more experience with C++ than Rust, but coding assistants do a good job on Rust.

0

u/El_RoviSoft 8h ago

Just don’t like language due to its constraints and lack of "10 solutions for the same problem"

5

u/HommeMusical 8h ago

lack of "10 solutions for the same problem"

That's kind of a virtue for me!

0

u/UndefFox 4h ago

What do you have against Rust?

The only thing that stops me from using it is partial borrowing not being added for how many years already. Why I have to pass all different class members manually on call instead specifying on declaration what parts the function uses, so if I pass a mutable reference to a method, it can call non mutable method that only uses parts that aren't in use yet.

I've checked some game engines code to see how they cope with it... yeah, 7 parameters for each function, bruh.

-2

u/Ameisen vemips, avr, rendering, systems 10h ago

I wouldn't mind C++ syntax but with borrow semantics - where unsafe is effectively just C++.

24

u/friedkeenan 9h ago edited 9h ago

I chuckled when it was revealed halfway through that this blogpost is yet another expression of Vinnie's longstanding grudge against the committee for deciding against the Networking TS. I guess he hopes to be more persuasive by attempting to roll it into the collective angst surrounding C++ dependency management.

It's also odd that he's replaced all the em dashes with hyphens. Is it supposed to make me less likely to think that this blogpost is LLM-written or LLM-assisted? This is a genuine question because I sincerely don't understand why the em dashes are replaced.

7

u/VinnieFalco wg21.org | corosio.org 4h ago

There's no grudge. In P4096 (https://wg21.link/p4096) I write:

> That history makes the following 3 statement necessary: the authors no longer believe the Networking TS would have been right for C++. The committee's conclusion was correct.

20

u/UndefFox 10h ago

Reads like yet another rant about not having standard for distribution without many new points to me... didn't address why it is like this either, (which is probably because: a lot of old libraries weren't designed for modern ways, old standards, and simply not many people who want to rewrite the whole lib from base, unlike Rust guys and so on...), nor provided pros/cons for "just grab of the shelf" mentality in Rust.

Points stands that we have a problem with package distribution/standardisation, but the substance of non consumer view feels non existent/

14

u/ijustlurkhere_ 10h ago

I hate this, because the more I read it the more I agreed - he's right. I love c++, used it for over 20 years, and I see his point.

24

u/aoi_saboten 8h ago

I will get heavily downvoted here but I think it is already too late for C++ to catch up and it is doomed to die in the professional scene since alternatives are catching up. For example, Rust is slowly being embraced by embedded (embassy, ESP32, ST), gpu programming (cuda-oxide, zluda, wgpu)

7

u/Nothing_from_void 5h ago

ESP32 with Rust genuinely sucks, you have to drop into the C API constantly because the rust library has trouble keeping up. Also the build artifacts are enormously bloated; like you build it a few times and all the sudden your build output dir is like 50GB.

It also makes no sense to write GPU code in Rust rather than the native shader language, like why add another compiler in front of your shader. Generally you're not writing a huge volume of GPU code, mostly you are being really careful that it does exactly what you want and it's as fast as possible, adding Rust in there is just increasing the ambiguity.

And I say this as someone who has largely replaced C++ with Rust, but those are two project types where Rust is genuinely a poor fit

5

u/RagnartheConqueror 4h ago

Rust is not as good as people think

-1

u/aoi_saboten 5h ago

I did not claim Rust is a great fit but that alternatives are gaining traction and it is only a matter of time and effort to get better developer experience

•

u/Nothing_from_void 3h ago

for those use cases, I don't think Rust is actually gaining traction though

14

u/mungaihaha 7h ago

C++ might die one day but the language that will kill it will not be Rust

10

u/graphicsRat 6h ago

C++ will die a few decades after COBOL

3

u/SkoomaDentist Antimodern C++, Embedded, Audio 5h ago

So sometime in the 2090s?

5

u/t_hunger 4h ago

Rust won't kill C++, but it has already taken developers, users and money out of C++'s pool. After Java, python and others have already taken a hefty toll, there is not that much left anymore.

4

u/mungaihaha 4h ago

C++ is still the industry standard for games (unreal, unity), browsers (chrome, firefox), compilers (llvm), media software (adobe), hft, and many other fields I am not remembering right now. 'hefty toll' how?

2

u/kAy- 4h ago

Adobe is slowly moving onto Rust as well. C++ still has a strong place but it's undeniable it's shrinking. Not that I like seeing it, but it's the sad reality.

2

u/aoi_saboten 4h ago

Browsers are embracing Rust btw, one could say that C++ code in them is legacy. Unreal engine announced that they are removing blueprints and C++ scripting, Verse will be used for code, so only engine itself is in C++ which is the same for Unity but game engines using C++ (not for scripting) is a weak argument for it to be industry standard imo

1

u/t_hunger 4h ago edited 3h ago

When I started with C++ it was widely used for enterprise applications (all those customized applications companies use), web backends and scientific computing. It is pretty niche in those areas now, maybe somewhere in the back to speed up something.

I am not sure I'd consider games as a prime example of C++... gamedevs use whatever the engine supports best and write some wierd code that does not look like "normal" C++ anyway:-)

•

u/ComedianMuted5486 2h ago edited 2h ago

Browsers are, for the most part, not using C++ for any major new subsystems.

JPEG-XL support was delayed specifically so that an implementation could be written in Rust. Nobody wants a brand new media codec written in C / C++. The risk is too high. People have gotten murdered because of bugs in media codecs (allowing their devices to be hacked by nation states). Jeff Bezos got blackmailed using one. Memory safety issues in the original implementation were explicitly one of the reasons they didn't move forwards with it years ago.

https://developer.chrome.com/blog/jpeg-xl-in-chrome

Chromium is already nearly 6% Rust code. Doesn't sound like much but it's a massive codebase with decades of history and they only started a few years ago. Firefox is 20+%. Ladybird started as pure C++ and then abandoned ship and switched to Rust.

•

u/mungaihaha 21m ago

not using C++ for any major new subsystems

Not accurate. In Chromium’s main branch history for Nov 1–30, 2026, Rust files accounted for 5.04% of file modification events; C++ files accounted for 94.96%

•

u/ComedianMuted5486 17m ago

That is a completely different thing and an argument that I did not make. Edits to existing files and new files in existing subsystems written in C++ are of course almost certainly going to use C++.

I am not talking about that. I am talking about the addition of new components. New media codecs, big new features, smaller components like font parsing and rendering being rewritten and replaced using Rust, etc.

I don't understand why you think this is a gotcha. 5% of edits being to Rust files is entirely consistent with, quote, "Chromium is already nearly 6% Rust code."

If you want to provide a counterargument, point to some net-new, self-contained subsystem that has been added recently which uses C++

21

u/EC36339 10h ago

C++, the language, was never in the way of building a better library ecosystem.

It's rather that the community doesn't want ONE system and that there are many, and new ones every year.

This is a feature, not a bug.

6

u/simonask_ 7h ago

C++ the language is actually very much standing in the way of a better library ecosystem in several ways. Modules were literally an attempt to fix that, but spotty compiler support and several deficiencies render it ineffective thus far.

How does it stand in the way, you ask?

Reliance on preprocessor macros for enabling/disabling features at compile time. These make it easy to run into the second way, which is sensitivity to ODR violations. Which is largely a result of the decision by all compilers to provide a stable ABI, so they can have first-class support for dynamic linking.

There are benefits to these tradeoffs too, but the downsides are also clear.

5

u/EC36339 7h ago

Not language problems but legacy code problems

8

u/t_hunger 7h ago

IMHO the biggest hindrance is not technical but social. "We never did that before" is a super common reply to any attempt to change anything.

In the end each community gets exactly the tooling it is collectively willing to (barely) tollerate.

15

u/Minimonium 6h ago

Surely that there could be some connection as to why just a hardened standard library fixed a massive amount of bugs and the fact that many do not use external dependencies?

Surely there could be an argument that memory safety, with rich in-language annotations that enable proven local analysis, helps people to adopt external dependencies with more confidence?

Vinnie is still so butthurt from the drama ten years ago, he's shying away from the fact that ASIO in the standard library would have all the same stabilization problems, even worse as the design at the time was broken so much I asked Richard to help me port a few old ASIO executors to new query-based ones and we failed to do so.

It's that irrational fad-driven mindset that is so common among the C++ "leadership" that anything that is not a complete feature is a waste of time.

For the same reason I see the same people without any experience in package management whatsoever making delusional claims - often accompanied with toxicity if not outright accusations of incompetency towards package manager maintianers.

For "leadership" there is no road from A to B. There is only B and they want someone else to make it happen.

For dependency management the best shot C++ had were the ecosystem papers with intermediary formats. The C++ ecosystem is massively fractured. The C++ standard is just a piece of paper that is merely lucky that the reality does not diverse too much from it (yet).

So you need to enable ways to gradually evolve the existing ecosystem into communicating with each other instead of spawning more dialects (now with the DoA standard library flavour). But the "leadership" through their actions made their position very clear that they would oppose anything tooling related and they have the leverages to drown the standard if they wish to.

The whole idea of a committee working group developed package management is absurd. You would ask someone about hermetic builds, they would stare at you with glassy eyes, then proceed to complain about Rust paying evangelists to attack C++ (actually what was voiced internally) and derail everything.

Also "profiles" is just a toy that can never work as it's based on wishful thinking and a delusional belief that static analysis authors are idiots.

8

u/VinnieFalco wg21.org | corosio.org 4h ago edited 4h ago

Earlier this year I published a paper which takes the position that the committee was right not to standardize the Networking TS. I also think that the Rust approach, standardize the narrow waist (a small async primitive) and let the ecosystem converge on the preferred networking and I/O shape, is the best way forward.

For this reason, we are no longer pursuing the standardization of Corosio.

See: https://wg21.link/p4096

5

u/Lopsided-Wave2479 10h ago

Losing a competing edge is bad, but you can compete with being really good in something else.. albeit if you do that you risk becoming a niche language. And thats maybe okay? C++ can't be Rust, but humans can learn both and use the right tool for the right job.

7

u/James20k P2005R0 6h ago edited 6h ago

Leaving the runtime outside std gave Rust something stronger than an ISO library standard: a de facto standard that could evolve before locking in

This is something that gets so incredibly turbo missed in committee designs. The graphics proposal was a great example of this, in dozens of places it asserted that it was all implementable on real hardware and could be accelerated, except a cursory glance showed that it simply wasn't true. Its weird to me that it didn't get more pushback on that front, claiming that it was implementable on GPUs and high performance with absolutely 0 evidence

But here's my question: Why standardise it? Graphics libraries are a moving target, as is graphics hardware. Library APIs evolve, D3D12/Vulkan is evolving rapidly with copious extension support. If you want to render graphics, use SFML or SDL and then go to town

Any standardised graphics library will always be strictly worse, the end, because its unable to evolve with the times. I do not know a single graphics toolkit that has not had to radically change over the last 10 years to stay relevant. The useful lifespan of a C++ graphics proposal would be under 5 years

Did the Standard Actually Need std::execution?

Its even more on the nose that the next topic is about std::execution, because I have exactly the same problems with std::execution as the graphics proposal

std::execution claims to have high performance support for GPUs. There are some very basic tests of std::execution on CUDA with stdexec, which will never support other hardware as it is dependent on Nvidia's CUDA compiler. People often aren't aware of how much difference there is between AMD/Nvidia/Intel/Integrated/TimApple/Linux/Windows/Stupidlaptops when it comes to GPGPU-land, so this is not a good sign

I don't think any graphics/gpgpu programmer would look at the API of std::execution and think "this is good", but lets sidestep that. These examples provided in the repos are incredibly basic:

https://github.com/NVIDIA/stdexec/tree/main/examples/nvexec

There's simply no performance major tests in the wild that I can find. Nobody's compared stdexec to SYCL, OpenCL, Vulkan, HIP (or whatever AMD is currently smoking), D3D12, or CUDA as far as I can find. The std::execution authors simply assert that it is high performance, which is not good enough. If you go googling for std::execution GPU performance data, or stdexec gpu performance, its very difficult to find much evidence that anyone has ever actually used it in a serious capacity

And yet this is apparently enough basis to claim that its fast, implementable across all hardware, and high performance 🤷‍♂️ where's the evidence? We have HPX as the only cited toolkit which has any usage, but the GPU side of it appears to have been received pretty negatively in general:

https://mcopik.github.io/assets/pdf/2016_hpx_gpu_slides.pdf

This 2022 cern paper specifically calls out HPX's GPU support as being unusably bad: https://cds.cern.ch/record/2838149/files/ATL-SOFT-SLIDE-2022-551.pdf

Worse single-node performance than TBB

HPX needs compute graph expressed as functions taking and returning futures

Appear to be limitations to what can be wrapped in a future

Built in CUDA support is very limited

Ended up using CPU tasks calling CUDA directly

Need to manually throttle submission into HPX to control resource use

So they were forced to sidestep the entire GPU support because reports from a pretty major collaboration said that it was crap, in 2022, shortly before S&R was standardised

Then in 2024 they published a new paper:

https://escholarship.org/content/qt9qs8h4b3/qt9qs8h4b3.pdf

Our initial standalone evaluation of HPX showed a promising outcome for HPX, we were able to work around the identified challenges. The integration with Gaudi revealed new bottlenecks. It would require a major redesign of the Gaudi scheduler to solve them

Where is the evidence that people want this GPU functionality, and that it is good, used, and high performance? How is this an acceptable bar for getting a feature into C++?

Now I have to get back to translating 1850s french artillery documents

3

u/VinnieFalco wg21.org | corosio.org 4h ago

I want to say on the record, that wg21 should not attempt to standardize networking and should instead focus on delivering a usable coroutine concept which enables third parties to build composable libraries. And it is not std::execution::task as I explain in P4089 (https://wg21.link/p4089)

3

u/lanwatch 5h ago

which will never support other hardware as it is dependent on Nvidia's CUDA compiler

Maybe that was a feature, not a bug, for the supporters of std::execution?

14

u/simonask_ 10h ago

Excellent writeup. So, so many of us saw this years ago and bailed ship - not because Rust covers every single use case that C++ covers, but because the tradeoff is extremely in Rust's favor for our use cases.

Rust doesn't have a stable ABI (so authoring dynamic libraries is a bit of a pain), it has less advanced metaprogramming capabilities, and there are a few other minor shortcomings. But the shortcomings are completely dwarfed by some extremely significant upsides, and memory safety is barely in the top 5.

I mean, statically checked memory safety is quite the luxury, but if you're already writing correct C++ (as in, free of UB), you're mostly already writing the same code you would write in safe Rust. What makes a huge practical difference is the crates ecosystem, sensible package management, and an overall more convenient modern language.

2

u/mversic 7h ago

Rust doesn't have a stable ABI

I'm going to take an opportunity to promote here because it is really difficult to find people who care about stable ABI in Rust. I hope you'll have a sneak peak at least 😄

https://github.com/mversic/co3

1

u/simonask_ 5h ago

Looks cute. Needs an LLM usage declaration before I'd take a closer look.

4

u/mversic 4h ago

I totally get it. There's so much slop around we cannot tell what's worth our time.

this is 3 years in the making. LLM usage ramped up over the last year. There's a few articles I published on the topic you may find more worth of your time

4

u/misuo 9h ago

I think Bjarne will agree that C++ needs to become easier to use.

5

u/jinmao6700 10h ago

how do you even solve that without breaking 40+ years of backwards compatibility ???

10

u/Gloomy_Necesary 7h ago

You break it ! This industry needs to come to terms that we occasionally need to make breaking changes. C++ is a monster of a language because it never wants to break backwards compatibility.

•

u/mkeytail 2h ago

Just like Windows has realised it had to do - a big long list of deprecated/removed features.

You only have true control when the surface is small enough.

1

u/sweetno 4h ago

I'm not quite sure what kind of backward compatibility is meant if you compile the world anyway. And yes, it will break on compiler upgrades anyway.

-3

u/KoziFarma 7h ago

Is backwards compatibility really still an issue in an age where you can update entire codebases in a couple of hours?

Say tomorrow the committee decided to correct some terrible naming choices and get rid of say std::vector<bool>. Would it really take that long to fix all your old code with an agent?

There's also nothing stopping anyone from compiling existing modules with existing conpilers and then compile new code with new non backwards compatible compilers.

4

u/Additional_Path2300 6h ago

Yes, it is. Not everyone can use agents or update everything.

4

u/bert8128 9h ago

4200 lines per day for 50 days. More than I can manage.

11

u/SkoomaDentist Antimodern C++, Embedded, Audio 7h ago

His Claude just goes brrrr…

1

u/VinnieFalco wg21.org | corosio.org 4h ago

Gemini now. I have banned Anthropic models.

•

u/wyrn 2h ago

LLM fans 1 week ago: hand coding is dead, claude is better at coding than humans, ai isn't going away, use ai or be left behind.

LLM fans today: claude is sabotaging my work

Maybe the true AI was the slop we wrote along the way.

4

u/pacafan 8h ago

Why Conan and vcpkg rely on massive git repositories for recipes goes beyond me. All the updates are slow and you have to go through gatekeepers. Whereas most other package managers you create an account and publish... Every couple of weeks I tell myself I should fork Conan or vcpkg and make the backend distributed with simple file indices and metadata where you can have cheap and cheerful repositories that projects can publish their own packages without going through the gatekeepers.

8

u/drodri 7h ago

Conan had a "decentralized" contribution process, with a central server, like crates.io, PyPI, npm, etc, in the Bintray servers. It was a disaster, packages being very low quality, working only in some platforms but not others, users duplicating packages for the same libraries and more importantly, a huge security risk.

For a new approach without central gatekeeping, check the new ``git`` requirements feature for (source-only, not binaries) Github dependencies, without a centralized server: https://docs.conan.io/2/devops/git_requires.html

2

u/lanwatch 6h ago

git_requires seems nice.

How would you say crates.io avoids (or doesn't) the issues that surfaced with the "open conan center"?

•

u/drodri 1h ago

Mostly because crates.io already has a standardized way of building and consuming libraries. The problem is not that much the "central" location, but the standardization of the mapping from sources to binaries. With Rust, cargo is the absolute standard in this process. In C/C++, this doesn't exist at all, not only because of the different compilers, toolchains and most importantly in this regard, build systems, but also because even within the same build system, the process of creating the binaries is not standardized. Different projects will decide to build their binaries completely differently: some will hardcode compiler flags or C++ standard in their build scripts, other will use different conventions for deciding if a library is static or shared, or different approaches for enabling or disabling features.

Also, because of the historical lack of package managers, open source libraries that existed before things like Conan or vcpkg existed, did vendor their dependencies as a pragmatic way to distribute their code. So package managers like Conan and vcpkg have to actively un-vendor those by patching the upstream build scripts to allow those libraries to be correctly packaged and redistributed together with other libraries. These un-vendoring introduces a new dimenson of variability in how things are built, because a library that was previously built in isolation now might need to play with different versions than the vendored ones to play with the rest of the ecosystem. And the way of handling that unvendoring might be different for different users depending on their specific needs. Kind of a chicken and egg problem.

3

u/pacafan 6h ago

Well then the question is why do decentralized contribution work for pypi, npm etc. Sure they also have low quality stuff. This maybe points to the horrific package and build management on C++ - fragmented etc. And of course adding another tool won't solve it. It would be great if C++ could standardize "packages" or "libraries" (quoted because the definition will need work) so that we can get rid of the fragmentation.

The gatekeeping process is obviously not working, otherwise more projects would have adopted it instead of vendoring code.

•

u/fortsnek274 3h ago

It would be great if C++ could standardize "packages" or "libraries"

I'm a great fan of CPS of course. If CPS were commonplace, downloading and using libs would be easier. A binary release would have CPS files and you'd just point your build system at the CPS directory.

But yes, dependencies need to work together. Need some way to look them up. Maybe it could just be a list of git urls if you assume that every library can be built the same way. Minimise the centralised part. Then you'd need some form of Standard Source Package format.

•

u/drodri 2h ago

It is very related to the huge configurability and variability over the ways to compile C/C++ libraries. Not only using different inputs, like different C++ standards, but also there are many libraries that have tons of configuration options: with/without SSL support, building as static or shared libraries, with/without support for compression with zlib, etc. There are popular libraries out there that have many tenths of such configuration options.

And these options don't exist or don't support different platforms.

It is basically impossible for one person or even an organization to build packages that serves the whole C/C++ community, with support for all that configurability. This is what makes C/C++ different to other languages and ecosystem.

Now, if you allow a decentralized way of creating packages, users will create different packages with partial support for different OS, or supporting different subsets of those build options.

The process of standardization for packages in C++ is called Common Package Specification (CPS), and we are actively working on it, see recent talks at conferences like CppCon or using std::cpp.

4

u/Anxious-Resist8344 6h ago • Bravo

Why should I spend the time reading something that you didn't spend the time writing? The levels of slop here are insane!

C++ should have stopped at C++17 and it would be a beautiful language today, instead they decided to keep going, and going, and going right to where nobody cares or want to go :)

2

u/imaginary-inc 9h ago

tbh, for an application like Runvil, C++ might not be the right choice. I would have used golang instead of Rust, mainly because I can develop such applications faster with Go than with Rust. But it's a personal choice. The point is that many languages are better suited for such applications than C++.

5

u/VinnieFalco wg21.org | corosio.org 4h ago

The choice was not based on the language, it was based on the availability of existing libraries/crates that do the heavy lifting for agentic programs. Right now Python and Rust are the top languages not because of the language features, but because their ecosystems have exploded with useful and necessary libraries. This explosion has not happened in C++.

•

u/imaginary-inc 2h ago

True for this kind of application. 

3

u/sweetno 4h ago

This leads to the uncomfortable question, what C++ is suited for and is it.

•

u/imaginary-inc 2h ago

Well lots of other things where C++ has a strong ecosystem even momopoly or duopoly with C.  Some examples Gaming, HFT, Scientific Computing, HPC, EDA tools, FPGA-C++ accelerators, robotics, all of AI low level close to GPU. Embedded systems including Networking, Automobile, iot, consumer electronics, drones, and lots of other stuff which you can call embedded. I work in few of these areas. In these domains C++ has very strong ecosystem and cmake has become defacto standard for build.. you get everything out of the box with well mature libraries.   

•

u/VinnieFalco wg21.org | corosio.org 2h ago

Yep there are many things which C++ is great at, and no alternatives on the horizon.

2

u/TheRavagerSw 5h ago

I really do not understand why the desire for a package manager like cargo doesn't die.

We need a decentralised solution. Not another slop factory like rust.

•

u/UndefFox 26m ago

And when distribution is handled by central company, it makes language possibly be affected by politics. C++ libs can be obtained from wherever you want, tons of mirrors/copies. If political situation gets worse, and countries block each other fully, how one will get cargo to work? Centralisation + being politically vulnerable isn't a good combo in this day and age/

1

u/sooka_bazooka 9h ago

Is Carbon coming anytime soon?

10

u/pjmlp 9h ago

Depends if you are a Google employee, which is their primary user base.

However their funding might be in jeopardy, now that Google has started to push for AI rewrites instead.

Carbon: graduating from the experiment at NDC Toronto 2026.

Scaling Memory Safety: AI-Assisted Rewrites of C/C++ Dependencies to Rust from Google Security team.

4

u/sooka_bazooka 7h ago

Nice talk at the first link, hope they can deliver something next year. At least their discord indicates the language is not cancelled (yet). 

Rust is awfully unergonomic 

1

u/Patient_Day7829 6h ago

One day cpp will start using smiley
after ^^ and other combinations end

1

u/ResistiveBeaver 4h ago

Why though?

1

u/RagnartheConqueror 4h ago

I’ll look into this

-1

u/feverzsj 7h ago

Yet, C++ is still the core language behind every AI/ML framework/system. Musk even said they rewrote Grok with full C++ stack, because "Real men manage their own memory".

0

u/veritron 4h ago

and funnily enough, it's not like cargo and all that other crap in rust's ecosystem is that good either. even for a relatively small project, it's very easy to end up with hundreds of gigabytes of rust dependencies and slow build times, and good luck auditing what actually goes into a rust product. many of the problems people were warning about with these build tools actually happened with cargo. similarly rust doesn't have what tokio does in its standard library and the consequences of that are pretty dire and annoying. a lot of what is being teased as strengths in this article are things i find insanely annoying about dealing with rust.

-3

u/Amilektrevitrioelis 6h ago

No, it doesn't.

C++ needs to be taken outside behind the shed and, y'know.

As for why, just watch this.

•

u/DragonflyOk9274 2h ago edited 33m ago

C++ is a great language and it’s the one I’m able to be the most productive in. However, the lack of real memory safety is a huge hindrance to me, and I feel that using it for production apps (client or server) carries a lot of risk now, especially with the ease at which people can use LLMs to find exploits. Thus, even though I don’t want to, I feel like it’s best long term to move away from it, unless the standards committee can actually come up with a solution. A lot of people have already left, but other languages like Rust are not a panacea and come with their own problems.

There are only a few things keeping me in C++ and not in Rust:

  1. Metaprogramming / Templates
  2. Constexpr
  3. Standard Library (algorithms) and iterator model
  4. Allocator + manual memory management support

Unfortunately many of the new things that the C++ committee focuses on aren't really relevant and somewhat make the language worse. To me, putting ranges inside existing algorithm headers means that all of my compile times increase drastically when I use -std=c++23. I understand that they want vendors to be able to provide their own implementations of libraries, but I end up using just one (libc++) across all platforms anyway.

The lack of memory safety is becoming more important now that the cost of finding exploits has dropped so much with LLMs. Even if I keep my code closed-source, I have to worry about every open source dependency I rely on to remain maintained and fuzzed. I have had to switch off of some C++ libraries already because they would have to handled untrusted inputs and I found so many bugs in a one-hour fuzzing session that I figured it wasn't worth trying to fix.

The preference for ABI stability is completely irrelevant to me -- I more or less recompile all dependencies anyway, and when I need my libraries to be used by other executables I typically provide a C interface shared library.

There are some great things. The standard library lets me write my own container, provide iterators, and call std::sort on it, std::lower_bound to find the element I want, etc. I don't have to implement my own partition_point for my container!

My data doesn't even need to be contiguous -- I can put them in different pages, or have them use a ring buffer (double ended queue in fixed storage), and as long as I provide the necessary iterators I can get access to a multitude of battle-tested, well defined algorithms with barely any work on my part.

Similarly, I can write an algorithm I want that uses iterators (or ranges!) and not even need to know what data type it will operate on.

But, the newest standards don't seem to be adding things that make my life easier or better.

-3

u/KoziFarma 7h ago

TL;DR:

  1. Lack of package management and therefore packages, meaning slow development speed
  2. Bloated standard library that solidifies bad design choices forever.

Add that to almost every standard library feature that has come out since c++17 is an overcomplicated illegible mess. Especially in the age of AI, code should be first and foremost legible.

It seems the only thing standing in the way of rust dominance these days is compile times 🤦🏼

-1

u/sweetno 7h ago

Uh-oh.

-5

u/Fantastic-Net-8774 5h ago

Meh. The borrow checker is overhyped, there are multiple classes of concurrency bugs that Rust does not catch for you, C++'s design invites pessimizations that make C a better choice for low latency work, I'd rather use Golang for almost everything else.

2

u/SkoomaDentist Antimodern C++, Embedded, Audio 5h ago

What are these "pessimizations"?

I haven't run into any despite having done plenty of single digit microsecond latency level work in C++.

1

u/Fantastic-Net-8774 4h ago

Yes I used to do work on 2110-21 targeting microsecond latency with special network hardware in C++.

Over reliance to RAII paired with the rules on moving around types with non-trivial cctors or dtors.

Move operator overloads, suddenly a vector resize you go from memcpy to iterating and copying struct fields. This plays badly with rules like "always use smart pointers" (because RAII totally == good and there is no nuance left in the discussion by most devs) maybe one day you will get std::trivially_relocatable but it was rejected out of c++26 deferred to c++29

The containers from C++ are a big upgrade over only writing in C but it is infectious. Everybody wants everything to be an object, and then they want to overload operators on the object, and the song and dance around lifetimes and safety gives you code that looks like you have really good performance work done... No stalls, high instructions retired... but its worthless instructions you didnt need.

You yourself have Antimodern C++ in your flair