Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

At the risk of being downvoted: I love Rust exactly for that. Or rather, for the combo of rustfmt and clippy. Both of which one could actually call "opinionated" not least on style.

I may not always agree but I go with clippy's suggestions anyway (which btw. just means passing --fix, most of the time, and they're done for me).

Because I care about other people reading my code.

One of the realizations the article touches on: if everyone uses the same idioms in a language, code becomes way easier to read for everyone.

This wasn't so obvious to me until recently. I was regularly still writing/touching a lot of C/C++ (25 years -- until ca. early 2021).

So everyone's lib/header/whatever uses their own style and when you also need to modify or at least audit/understand 3rd party code, you're kinda use to dealing with that. I.e. I would have said: what is all the fuzz about?

Or I guess I could also be saying: when you get kicked in the shin every day, it won't hurt so much any more after some time.

I never though of this as making such a difference until I started using Rust professionally: my shins hurt way less; mostly not at all as everyone is using rustfmt & clippy. In fact, many Rust repos now have these two coming out clean as a condition for a PR to even make it through automatic checks.



Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: