News for hackers. Stuff that matters.
Re:C++ to Rust Phrasebook by Tyr42 on Saturday May 31, 2025 @06:29AM (#44143293)
I've taken a look, and it's definitely expecting you to know some C++. Or at least, it spends equal time on both, which means it can't warn you about the foot guns in c++.
Re:C++ to Rust Phrasebook by skrishnamurthi on Saturday May 31, 2025 @07:28AM (#44143533)
It's definitely written from the perspective of someone who "knows C++". But I put that in quotes because there are (at least) two interpretations of that phrase. There's the person who doesn't know any C++ at all, and for that person, this is useless. But there's the person who knows a baseline of C++ but doesn't know modern C++, and they can use this as a way to modernize their C++ code while ignoring the Rust bits. But either way, yes, it doesn't warn you about C++ footguns (other than pointing you towards Rust <-;).
Re:C++ to Rust Phrasebook by jpc0 on Saturday May 31, 2025 @11:36AM (#44144947)
There are patterns diffused in this paper that are modern C++ only in the sense that anything post C++11 is modern C++. That was 14 years ago, you will be hard pressed to find a toolchain that doesn’t support C++17 at this point, yes there is probably some unfortunate person building for debian old-stable or some ancient but still supported redhat but at that point you know you aren’t following modern practices and you have your reasons.
Re:C++ to Rust Phrasebook by pjmlp on Saturday May 31, 2025 @12:15PM (#44145255)
I will also debate that plenty of "modern" C++ features that people attribute to C++11, were already possible throughout C++ARM to C++03, but apparently many either weren't paying attention, or only renaming their C files into .cpp/.cxx/.C.

Just like the low level stuff done by MFC, and how much more ergonomic CSet++, OWL and VCL happened to be.