Ranter
Join devRant
Do all the things like
++ or -- rants, post your own rants, comment on others' rants and build your customized dev avatar
Sign Up
Pipeless API
From the creators of devRant, Pipeless lets you power real-time personalized recommendations and activity feeds using a simple API
Learn More
Comments
-
electrineer29763286dYou're supposed to configure the tool how you want. Especially, if you want something snowflaky like tabs instead of spaces.
-
C0D466944286dTabs are not fixed width, Spaces are - simples 🤷♂️
"But it doesn't matter"
Until it does. -
Lensflare17259286dSoon:
"You are required to use non binary indentation for a more inclusive and diverse program. At least 30% must be spaces, another 30% must be tabs and the rest must be other whitespace characters." -
usr--2ndry739286dyeah, and then they change their opinionated best practice recommendation rule sets so that our linter configuration becomes illegal itself after upggrading
-
ars14054286d@Lensflare we have banned the use of the word whitespace, as we consider it harmful and triggering for some minorities. We opted for the new term “code-spacer”, which we feel is more inclusive and rolls off the tongue.
Any person not abiding by this new term will be subjected to regulation as stated in the COC.
We will also be renaming the COC to POOP. Please follow our new Protocol of operations and practices. -
Lensflare17259286d@ars1 we make fun of it but there are definitely morons out there who would subscribe to that. And it‘s sad to think of it as a somewhat likely future.
-
Demolishun34671286d
-
fumey27286d@jestdoty what do you mean when you say illegal? Like you could get in trouble with the authorities?
-
fumey27286d@jestdoty haha I see. You mentioned political people so I thought this was some sort of legislation. You had me confused 🤣
-
lorentz15123285dI found rustfmt much better for formatting though and Clippy generally focuses on semantics, I'm honestly surprised that clippy said anything about your indentation.
-
lorentz15123285danother potential issue is that ``` blocks in doc comments are assumed to be valid doc-tests. If you mark the code block as JSON neither clippy nor rustfmt should bug you about it, and the test runner won't try to run it as Rust either
-
lorentz15123285dClippy has very strict rules for everything, you can disable them globally with #![allow(clippy::bad_rule)] but an allow clause on the enclosing function contributes to readability so global allows are more useful when you disagree with the values of the clippy devs rather than to address individual exceptions.
ps: this comment was originally higher up but I accidentally deleted it -
lorentz15123285d@jestdotty Ah, I didn't know about that rule but I guess it would've matched anything, no matter the markdown so all you can do is disable it. I'm surprised that they don't have an exception for tabs preceded by newline though, it would be convenient for things like yml and real doc comments would still be caught by actual indentation lints.
Related Rants
wow now I have native linter tools telling me tabs are illegal when they're not
can these political people vamonos
rant
spaces
tabs