4 ms·
The article makes a mistake here in interpreting the results of the StackOverflow survey (https://survey.stackoverflow.co/2022/#technology-most-loved-dreaded-an
by nindalf 4y ago
The article makes a mistake here in interpreting the results of the StackOverflow survey (https://survey.stackoverflow.co/2022/#technology-most-loved-dreaded-and-wanted https://survey.stackoverflow.co/2022/#technology-most-loved-...). Here’s the summary with respect to Rust
- 9.3% of respondents use Rust (#14)
- 87% of respondents who already use Rust would like to continue using Rust. (Most loved)
- 17.6% of respondents who don’t already use Rust would like to try out Rust (Most wanted)
While I generally agree with the sentiment that Rust can, should and probably will improve I don’t see the survey results or your anecdotal experience as cause for alarm.
It’s far from the most popular language (JS 65%) or most popular language without a runtime (C++ 22.5%). But that’s fine because it’s relatively new. The survey indicators a big appetite for trying out Rust among developers who haven’t tried it out already, indicating that the language could continue to grow in popularity.
- pclmulqdq 4y agoIt's worth noting that Rust is about the same age as most of the modern C++ paradigms that you see all over C++ codebases these days. C++11 came out at around the same time as the Rust project reached bootstrapping, and C++14 came out less than a year before Rust 1.0. It would not be an exaggeration to say that most of the C++ you use today is about the same age as Rust.
- nindalf 4y agoSo even while working with modern C++, only 48% of developers want to continue working with it? And only 7.6% of developers want to learn it?
- pclmulqdq 4y agoPretty much, and for a few good reasons: - Most C++ projects are not greenfield, and C++ programmers are often working with 10-20 years of cruft in their codebases. - Most of those codebases are also somewhat object-oriented, and thereby tained with "enterprise Javaness." - C++ has a number of high-profile detractors who are well-liked in the programming world, like Linus Torvalds and (in this sphere) Bryan Cantrill. Most of these detractors haven't touched C++ in 15-20 years and are still railing against the monstrosity that was C++03 and the thickness of the C++ spec (without actually using it). - C++ is widely used, and often not in places where it is appropriate or useful. When people use something, they see its rough edges. - C++ isn't "cool" in programming spheres.
- karmakurtisaani 4y ago> Most of these detractors haven't touched C++ in 15-20 years and are still railing against the monstrosity that was C++03 and the thickness of the C++ spec (without actually using it). Keep in mind that C++ standard is backwards compatible, so every monstrosity added is still there. You might not use it, but your (ex-)colleagues might have, and you might end up maintaining such code. Let's just say it doesn't exactly make it more appealing.
- HideousKojima 4y agoI imagine that, at least for younger devs, game dev would be the only real motivation for learning C++
- scruple 4y agoOr old (-ish, I'm early 40s). I'm back around to C/C++, haven't touched it since C++03 and C++11, having recently accepted a Senior+ role in gamesdev and moving away from a decade of backend work.
- galangalalgol 4y agoYou have been quite fortunate. Most of the c++ I come across is c++98. Or at best c++11 features sprinkled into c++98 code.
- jeremychone 4y agoThat is a very good way to look at it. Now, I am not a C++ dev, but how much effort would it be for a team to pick up C++ 20 if they only had worked with was C++ 11?
- pclmulqdq 4y agoIt's not that bad unless you're library writers. The functional programming parts and expansion of compile-time metaprogramming (constexpr/templates) are probably the biggest new features, but you probably aren't going to use the more complex parts. IMO the biggest changes in ergonomics for application writers are: * better iterator-based algorithms and iterators becoming more powerful than indexes and pointers * new helper objects like string_view that let you work more efficiently * functional programming and passing lambdas around is possible * "override void foo() const noexcept { ... }" - all the extra keywords (override, const, and noexcept) help you with correctness