3 ms·
As someone who recently tried to do "modern" C++ with no background in C or C++, it was absolutely horrifying compared to my nice cuddly managed language runtim
by dikaiosune 11y ago
As someone who recently tried to do "modern" C++ with no background in C or C++, it was absolutely horrifying compared to my nice cuddly managed language runtimes. I get that it's not meant to be a language that's quick to pick up, but the languages that OP decided not to use are quick to pick up in comparison. And several of them offer many comparable features (whether you're evaluating the metaprogramming, the performance, etc.).
- jmspring 11y agoNo background being key. Learning takes time. Coming from older versions forward of C/C++ (though most people don't crow about a particular version) is easier than what you propose. Having a strong foundation in classic languages and an ability to adapt to modern paradigms seems way easier than the reverse.
- dikaiosune 11y agoAbsolutely, that's a much better way to put it. But it's a situation that (I'd wager) many more developers are in, as opposed to already knowing an older dialect of C or C++. Given the growth the field is still undergoing, and the number of devs who never need to learn one of "the classics," I don't think it's bad to point out that there are good alternatives to C++ that are easier for someone versed in managed languages to pick up if they need some of C++'s strengths.
- jmspring 11y agoGiven the cyclical nature of this field, adaptability should be a core component of one's aresenal. For instance at a low level, machine to machine communication, C over the internet, Node APIs, etc shouldn't matter to getting things done... API and functionality can be decoupled, but you will still need to have someone available to understand the path from A to Z
- akhilcacharya 11y agoThat's the boat I'm in. I really would like a good project that would let me learn modern C++, but I haven't found one in an interesting space yet :/
- dikaiosune 11y agoI ended up learning Rust and I will never look back!
- MrScruff 11y agoIs Rust performance comparable with C++ yet? Last time I looked it was similar to Go. One of the things that C++ offers is an optimisation route where performance is really important.
- gbersac 11y agoYes it is as fast as c++ now.
- dikaiosune 11y agoThere are a few factors which for my current use case are helping rust outperform my previous c++ implementation. One of those is that it's far easier for a beginner to reason about the performance characteristics of rust code. Another is admittedly that I understand the domain better now. My favorite reason is that rust let's me exploit non-trivial parallelism safely, so I can use more cores much more frequently, still with lower development effort.
- steveklabnik 11y agoIf you find something that's significantly slower, please file a bug. We should be in the same order of magnitude: sometimes faster, sometimes slower, but never significantly so.