> C/C++ programs are often predictable, memory issues are easy to catch

They are not. Memory-safety issues continue to impact major C/C++ codebases such as the Linux kernel and Chromium, sometimes manifesting as security vulnerabilities.

I've been around long enough to know, given enough time, we'll find out Rust isn't the panacea to all our language problems - just like what the parent pointed out about Java and it's memory safety promises back in the day.

It is indeed quite possible to write memory safe C/C++ code... and it's done every day. You never hear about how memory safe and performant all that code is... you only ever hear about the rare, high profile mistakes.

The problems with languages like C++ are more about how bloated it's become. There's 30 ways to do anything in that language, and 24 of them you're not supposed to use anymore! This leads to all kinds of problems as more people touch the code over many years and C++ standards.

I'm very interested in seeing Rust mature in this space... if not for memory safety promises, then for it being a "fresh start" for systems programming without all the legacy baggage C++ has.

> we'll find out Rust isn't the panacea to all our language problems

I don't think anyone is suggesting it will be. It's not about to supplant Ada SPARK, for instance, as Rust is far behind in terms of formal analysis.

> just like what the parent pointed out about Java and it's memory safety promises back in the day

Java does address the memory-safety issues of C and C++. You can't have a buffer overflow vulnerability in pure Java code. You can't have any kind of undefined behaviour due to memory-management mistakes in your code. You can't double-free, or use-after-free, or deference a pointer to a local variable that has gone out of scope. You can't trigger undefined behaviour through a read-before-write bug in your code.

It's possible to have a memory leak in Java, if you retain references to objects for too long, but that won't ever give rise to undefined behaviour.

Of course, there can still be bugs in a JVM, but that's another matter. All languages are vulnerable to compiler bugs.

Other languages like JavaScript do the same. It's possible to leak memory, but it's never possible to trigger undefined behaviour from JavaScript. That's a vital part of its security model.

> It is indeed quite possible to write memory safe C/C++ code... and it's done every day

That doesn't sound right.

There's a reason I gave the examples of the Linux kernel and Chromium. They're written by highly competent developers, but they still have subtle memory-management bugs. Most C/C++ codebases are written by less competent developers, but are of far less interest to attackers, so it's of less consequence. Their memory-management bugs are likely to go unnoticed forever.

I agree it's possible to write C/C++ code without memory-management bugs (there are various formal development systems for C), but it's a significant challenge. I'd hope avionics software, for instance, would be entirely free of such bugs.

> You never hear about how memory safe and performant all that code is... you only ever hear about the rare, high profile mistakes.

They're not that rare, they're a major source of serious security vulnerabilities, and languages like Safe Rust can close the door on them entirely.

> The problems with languages like C++ are more about how bloated it's become. There's 30 ways to do anything in that language, and 24 of them you're not supposed to use anymore!

Agreed. C++ is quite a lumbering monster of complexity. Ada also has a reputation for being somewhat bloated, but it's not as far gone as C++.

> if not for memory safety promises, then for it being a "fresh start" for systems programming without all the legacy baggage C++ has

Keep an eye on Zig, too. Also D and Nim, and perhaps Vala. Also the lesser-known ZZ and Dafny languages, which look very interesting.

https://github.com/aep/zz

https://github.com/dafny-lang/dafny