News for hackers. Stuff that matters.
Re:What If C++ Abandoned Backward Compatibility? by amelius on Saturday March 28, 2020 @06:25AM (#22710312)
> One of the main reasons to stick with C++ (and C) is that the investment you put in the code you're writing right now, no matter how fugly it is, will be there and keep working in the future.

Except slowly people will be writing parts of it in Rust, or they would be using libraries written in Rust (because availability), and then after a while people get annoyed of using more than one language and the whole project will be rewritten in Rust. Of course, at that point, a new language will be invented and Rust code will be looked at as rusty :)

Re:What If C++ Abandoned Backward Compatibility? by kllrnohj on Saturday March 28, 2020 @03:59PM (#22713896)
Rewriting parts in Rust would require Rust to have good C++ interop, which it doesn't. At all. Rust has good C interop, so if your code is already divided into C-abi shared libraries then you're golden. But if it's not then Rust migration really isn't an option.

And realistically I'm not entirely sure how you can add C++ interop to Rust without also ruining Rust. It's a hard problem to say the least.

Re:What If C++ Abandoned Backward Compatibility? by bsder on Saturday March 28, 2020 @04:50PM (#22714234)
Does anything have good C++ interop?
Re:What If C++ Abandoned Backward Compatibility? by pjmlp on Saturday March 28, 2020 @06:41PM (#22714844)
D, .NET and COM/UWP.
Re:What If C++ Abandoned Backward Compatibility? by otabdeveloper2 on Saturday March 28, 2020 @07:01AM (#22710391)
> Except slowly people will be writing parts of it in Rust

Wishful thinking.

Re:What If C++ Abandoned Backward Compatibility? by pjmlp on Saturday March 28, 2020 @07:18AM (#22710438)