Hacker News new | ask | show | jobs
by c-cube 959 days ago
The problem with your argument is that swift is not, and cannot be, a replacement for C++. At best it can be an alternative for some programs, and on macOS only; for the rest of the world it's not very useful. And rust is great but the thing it lacks here is a great C++ interop story, the way TS has with JS and kotlin has with java. There's not really any language with that today (maybe D?) that also has a compelling story of being modern and safer than C++.

In that sense, cpp2 might get to the point of being usable while having perfect interop with C++ (as in, you can use any C++ library trivially, and you can mix it with C++ in a codebase on a per file, maybe even within files, easily) before Rust or swift or Carbon.

1 comments

From point of view from Apple it is, for their own ecosystem.

It is also a reason why if you want modern C++ support on Apple devices, now you need to install clang yourself.

As Apple keeps focusing on Swift, with Objective-C for its companion.