Remix.run Logo
▲ drivebyhooting 2 hours ago

I used to be a C++ programmer but I haven’t done it in a few years.

I pretty much do all my low level vibe coding in Rust. Is C++ still relevant? What prevents Rust from completely supplanting it?

▲gucci-on-fleek 2 hours ago | parent | next [-]

Even if C++ is irrelevant for new code, there's so much software already written in it that we'll be maintaining it for decades to come. I'd argue that Cobol and Fortran have been mostly obsolete for new code for almost 30 years now, yet both are still widely used today, and they've even had major updates in the past decade [0] [1]. And there's even more software written in C++ than there is in Cobol or Fortran, so I don't think that C++ is going away any time soon.

[0]: https://en.wikipedia.org/wiki/COBOL#COBOL_2023

[1]: https://en.wikipedia.org/wiki/Fortran#Fortran_2023

▲jandrewrogers an hour ago | parent | prev | next [-]

Essentially all high-end systems code for high-performance and high-reliability systems is still written in modern C++. That language has many attractive properties, including safety features that Rust does not currently support.

Additionally, for pure performance requirements, C++ is still materially faster than Rust in practice. That may change some day. C++ has many issues but it is also objectively excellent at many things.

▲fancyfredbot 2 hours ago | parent | prev | next [-]

C++ is the third most popular programming language according to TIOBE behind C and python. It's got an 8.87% ranking. So yes it looks like C++ is still relevant. In fact C++ usage has risen slightly.

Rust is in tenth place with 1.44% ranking, it's rising fast but still has a long way to go before it catches C++.

I'm not going to speculate about why Rust hasn't yet supplanted C++ but I will say I don't find it surprising.

▲miffy900 26 minutes ago | parent | next [-]

Please for God's sake stop citing TIOBE.

A much more accurate snapshot would be Github - they recently published the top langauges for the year (so far, up til Sept 2026) by distinct monthly contributors and C++ comes in at 9 out of the top 10, and Rust doesn't even place in the top 10 yet, so yes it is highly relevant and prevalent, but not because TIOBE said so.

But, TypeScript, Python and Rust are the fastest growing languages, in that order, so also you cannot discount Rust.

https://github.blog/news-insights/octoverse/octoverse-commit...

▲afdbcreid an hour ago | parent | prev [-]

TIOBE is nonsense.

But, of course, there is still a lot of new C++ code written, more than Rust. I believe C++ will become legacy, but it's not there yet and even once that happens it'll take at least decades to stop writing C++.

▲willtemperley 2 hours ago | parent | prev | next [-]

Your Rust very likely runs in a C / C++ environment.

▲anonymous908213 2 hours ago | parent | prev [-]

99.9% of all system code in the world is still written in C/++. It runs your Java, C#, Javascript, Python, PHP, basically every production language that isn't Go or Rust. It runs the two most popular game engines in the world. It runs your phone, server, and laptop, no matter which of any you use. It runs your car. It runs almost every embedded and industrial application on the planet.

Is it still relevant, JFC. The way people on this forum manage to sequester themselves from reality. Let me reverse the question: is Rust relevant? Mozilla developed Rust, abandoned their Rust browser, and only 10% of Firefox is written in Rust. Maybe 1% of modules in Chrome and Linux are written in Rust, if that. And what of Rust applications written from scratch? Can you name ten applications that have, say, exposure to more than 100,000 users? Impossible mode: they can't be developer tools only used by other developers (uv, ripgrep, etc.), they must actually be applications used by enterprises or consumers.

▲devsda 2 hours ago | parent | next [-]

I read that as "is c++ still relevant for new features, given Rust and its popularity", not "who is still using C++".

Personally, I think it is still relevant. Many people thought Kotlin could overtake Java, Java reinvented itself with new initiatives/features and was saved from becoming irrelevant.

Rust also has the LLM advantage which is where I think the "if it compiles it works" nature of Rust is easier for manual changes and maintenance when needed.

▲afdbcreid an hour ago | parent [-]

Java vs. Kotlin is a different matter. It's still an open question if C++ even could match Rust's features, not to say if it (the committee) wants to, and the answer seems to be "no".

▲qtqtqt 2 hours ago | parent | prev | next [-]

> basically every production language that isn't Go or Rust.

Even in their case. Rust depends on LLVM which is wriiten in C++. Go needs libc on some platforms.

▲adzm 2 hours ago | parent | prev [-]

As a big c++ fan, new projects are generally choosing Rust, which I would agree with, even though I do indeed love C++