57
top 17 comments
sorted by: hot top controversial new old
[-] FizzyOrange@programming.dev 0 points 10 hours ago

Yeah he's dead wrong here. Even clang-format - easily the worst autoformatter I've used - is an order of magnitude more tolerable than no auto-formatting.

Sure it might not always be as good as what a perfectionist human would produce, but it's sure as hell better than what the average human produces, and it means you don't have to waste time ranting like this.

[-] PumaStoleMyBluff@lemmy.world 1 points 9 hours ago

He's not advocating for getting rid of the formatter

He's advocating for making it better

[-] vala@lemmy.dbzer0.com 1 points 10 hours ago

Why is clang-format actually so terrible haha? It's absolutely is, I just don't know why.

[-] OnfireNFS@lemmy.world 16 points 1 day ago

I like that rust is opinionated by default. It reminds me of prettier. I don't have to argue with teams about what code style were using. I can open up any rust project and know it's readable and formatted with the same specification as any other rust project

[-] sadfitzy@ttrpg.network 4 points 1 day ago

I just think it's stupid how snake_case won out over camelCase.

Now we have to use our pinky to hit an extra key every time.

[-] PokerChips@programming.dev 33 points 2 days ago

Well, he does have a point.

[-] sukhmel@programming.dev 3 points 16 hours ago

Agree, setting up rustfmt and then battling other developers about it's settings is not very fun. But having a standard tool with configurable settings that can be stored right in the repository is immensely better than not

[-] thingsiplay@beehaw.org 12 points 2 days ago

I am surprised that there are not common Rust formatting rules enforced at config level. Every project can have rustfmt rules file, that overwrite defaults.

[-] ulterno@programming.dev 1 points 12 hours ago

Because rustfmt does not have enough proper customisations.

I just started Rust a few days ago and after my code became >20 lines (following the docs, understanding the basics), I decided to look for a formatting tool for Rust.
I found out rustfmt, read :

Rustfmt is designed to be very configurable. You can create a TOML file called rustfmt.toml or .rustfmt.toml

and was kinda happy.

And since in cmake I use BreakBeforeBraces: Allman, I looked for a similar option.
Found out in the docs, it was not available in stable. inner-thoughts: How old is Rust? I already waited 4+ years before picking it up. Well, let's look up the unstable features on GitHub.
There are 2 configuration options relevant to the functionality.
Both of them have enough parts where they don't work, so they are useless even if I were to use the unstable version of rustfmt.
And it seems like either none of the people participating in that issue is good enough to make changes in its source code or the rustfmt team doesn't want that feature implemented.


And if someone requires a reason for Allman style for BreakBeforeBraces:
The Allman style makes it much easier to identify block scopes without having to rely upon IDE features such as highlighting.

[-] thingsiplay@beehaw.org 1 points 12 hours ago

Sure, it might be missing features. But the main point is that rustfmt is pretty standard in Rust and is easy to enable and integrate. So even if features YOU want to have are missing, there could be a default configuration of what is configurable. I would expect that from a big project like Linux. Linus should never be in the position he was, by Googling and finding these options. It should have been as a configuration enforced as standard for every contributor.

[-] ulterno@programming.dev 2 points 12 hours ago

Googling and finding these options

Well, it's not in that bad a condition.
All options (hopefully, because I didn't check) that are applicable to any version of rustfmt are available using rustfmt --print-config default and you only need to use the internet in case you either did not understand the option from the name or if you are looking for an option not in your specific version.

It should have been as a configuration enforced as standard for every contributor.

That was most probably just another instance of oversight, I'd say.
The one determining which configuration went into the formatting configuration (or the one making the default one, in case there was no config file for the Linux project), might have just not thought of that particular implication of the option been set.

[-] wander1236@sh.itjust.works 9 points 2 days ago

The format wars are getting too literal

[-] dataprolet@discuss.tchncs.de 3 points 2 days ago

Can we stop publishing an article every time Linus Torvalds looses his temper over some minor annoyance?

[-] ulterno@programming.dev 3 points 12 hours ago

You mean, "stop using nice and spicy original content made by a popular person, to create high ROI articles"?
In this world when you could have an article when <insert movie-actor/singer name here> sneezes in front of the camera, why would someone not capitalise on someone putting years of past experience and thought into writing an essay?

[-] spartanatreyu@programming.dev 38 points 2 days ago

I don't see any actual temper lost here.

In one case he points out that someone is making commits that have messed up a file's indentation, and to stop doing that because it's messing things up (they were).

In the other case he points out that rust's default format rules are wrong (in the context of version control readability, they are) and asks someone to fix them.

[-] thingsiplay@beehaw.org 6 points 2 days ago

Can we not?

[-] gtrcoi@programming.dev 7 points 2 days ago

I was thinking the same thing about a video I just watched covering Linus ranting to someone who asked a question on the mailing list about big endian support on risc5.

Basically some guy asked in a single sentence if there was a chance for support and Linus and everyone else wrote essays about how dumb it would be, and I'm wondering why bother reporting on such a niche and completely arbitrary tirade about experimental CPU architecture.

That said it did include Linus writing a long list of similar examples of hardware choices that he finds offensive that was entertaining, and that's probably why people report every time he rants about stuff; he puts a lot of effort into his opinions and it give people a lot to chew on if they are interested in those topics.

this post was submitted on 02 Oct 2025
57 points (91.3% liked)

Linux

9627 readers
269 users here now

A community for everything relating to the GNU/Linux operating system (except the memes!)

Also, check out:

Original icon base courtesy of lewing@isc.tamu.edu and The GIMP

founded 2 years ago
MODERATORS