Comment by bigyikes

3 years ago

> Rumor 5: Rust code is high quality – Confirmed!

> The respondents said that the quality of the Rust code is high — 77% of developers were satisfied with the quality of Rust code.

Well, that’s exactly what I’d expect Rust developers to say. Nobody loves Rust more than Rust adopters. Would be interesting to see more objective measures of code quality (e.g. defect rate)

Also, the type of person to work on a Rust codebase might also be more likely to write high quality code in any language, as compared to the average developer (or even average Googler).

People used to say "when people are forced to use Rust at their job, they'll start hating it, only hobbyists use it and that's why it's so beloved." Do you really consider people learning Rust on the job to be "Rust adopters" who are partisan? Is anyone who ever uses Rust a "Rust adopter" who is unable to give an unbiased opinion? Who would be able to give that opinion, in your view?

  • People who are adopting Rust now at their jobs are in most majority people who are so keen on using Rust to push it into organizational adoption. Most companies don't yet have legacy Rust codebases on which people are told to work, but instead choose to work on.

    This creates a self-selection, where Rust lovers work on Rust projects and report utopian happy-go-lucky times. It's normal for most technologies.

  • > Do you really consider people learning Rust on the job to be "Rust adopters" who are partisan?

    Not necessarily, but it seems not unlikely.

    > Is anyone who ever uses Rust a "Rust adopter" who is unable to give an unbiased opinion?

    It’s still a relatively new and niche language, so, yes.

    > Who would be able to give that opinion, in your view?

    Nobody, and maybe that’s my real point, which is why I’d like some metrics to supplement the anecdotes. This especially applies to Rust, but I think also applies to any language.

    Note that I don’t mean to imply that there isn’t value in anecdotes. There is.

    • I agree the post could include more concrete metrics than self-assessment, but more than 1000 data points, even self-assessment data points, are usually not called anecdotes.

    • > Nobody, and maybe that’s my real point

      To be honest, this is what I've taken away from this conversation so far: it doesn't seem like anything will satisfy your desires here.

      > which is why I’d like some metrics to supplement the anecdotes

      This conversation started with you not liking that the measure of quality is subjective, which is fine. How would you objectively measure code quality though? What metrics would you have preferred to see, other than the ones in this post?

      2 replies →

  • > As an engineering manager...

    > unbiased opinion

    If the engineering manager after putting so much effort into switching to Rust, and trying to convince upper levels, putting their head at risk and after busting balls for months to make everyone learn Rust, comes into the office one day and asks if we love Rust, we the 77% that want to keep our jobs would answer "OF COURSE WE DO!!!!! COULDN'T BE HAPPIER!!!", with a big smile.

    • This hasn't been my experience at all.

      Me and all the other developers I know complain endlessly about the tools we're forced to use. We complain to anyone patient enough to listen, including all the engineering managers. No one I know ever got fired or laid off for this.

It's a bit unfortunate that they aren't sharing this statistic for other languages. For example, I'd bet that rather fewer than 77% of Google C++ devs are satisfied with the quality of C++ code. I know that, when I was at Google, I wouldn't have reported satisfaction with the quality of my own C++ code!

> Well, that’s exactly what I’d expect Rust developers to say. Nobody loves Rust more than Rust adopters.

An increasing number of Android developers in Google are adopting Rust because of the org wide strategy rather than developer passion, so I guess the numbers in 2023 and 2024 would be more interesting to see.

Also since it's a young language, a lot of these people are probably writing in a newer codebase that doesn't have 15 years of early fundamental bad decisions and hacky refactors to make it painful to work in.

I'm sure there are developers who are like "wow, the quality of my code sucks in this language." But I'm not sure where they work and what they do.