Hacker News new | ask | show | jobs
by 20k 139 days ago
Yes. Unfortunately the committee has completely abandoned safety at this point. Even memory/thread safety profiles have been indefinitely postponed. The latest ghost safety lifetimes thing is completely unimplementable

There literally isn't a plan or direction in place to add any way to compete with Rust in the safety space currently. They've got maybe until c++29 to standardise lifetimes, and then C++ will transition to a legacy language

1 comments

Using containers and std::string for everything eliminates the majority of safety bugs.
The safety bar is way way higher.

The C++ WG keeps looking down at C and the old C++ sins, sees their unsafety, and still thinks that's the problem to fix.

Rust looks the same way at modern C++. The std collections and smart pointers already existed before the Rust project has been started. Modern C++ is the safety failure that motivated creation of Rust.

You need `GSL` and `lifetimebound` to approach most modern safety bugs.
If only the standard differentiated between programs that are "mostly" free of UB and programs that aren't.
Not really. We keep getting pointer-like types like std::string_view and std::span that can outlive their referents.