Re:A Guide to Porting C/C++ to Rust
by shmerl on Sunday January 29, 2017 @10:30AM
(#13514499)
This looks interesting, though I can't find much info about inheritance and code reuse there, which should be a major topic I suppose? Who is the author of this book?
[ Parent
| on HN ]
Re:A Guide to Porting C/C++ to Rust
by Manishearth on Sunday January 29, 2017 @05:03PM
(#13517002)
The book is incomplete.
Porting an inheritance model to Rust is ... interesting. You can emulate it with some macros, but usually you should redesign the idioms used based on the exact use.
Yes, I'm not talking about porting things 1:1. I'm talking about explaining OOP approach that Rust suggests, and may be examples of how this methodology can be applied to solve issues like code reuse, that C++ at times solves with inheritance and etc.