DEV Community

Discussion on: Is This Snowflake Code?

Collapse
 
joshcheek profile image
Josh Cheek • Edited

I could def survive in a codebase like that (I mean, hell, I can put up with the eslint nonsense). The closing curly braces are probably the hardest one for people b/c most people close blocks (I assume that's what they're called in Perl) at the level of the next line of code. Since we parse enough code that our brains eventually get competent at it without conscious focus, changing the indentation you close them makes it look (to most readers) like there's a bug. Ie my brain will subconsciously zero in on it, expecting to see a bug. But, that said, I'm sure I'd get used to it pretty quick and be fine. I've seen maybe 3 different brace styles in C and Java, and in the end was able to read all of them with minimal difficulty. So, no, I don't particularly have an issue with it (in your code, I'd probably reformat it if you sent it to me as a PR).

Personally most of the interactions I have on Stack Overflow are unhelpful and frustrating to the point that it's completely fallen out of use as an avenue for assistance. I think I went about 3 years without logging into it, until recently a lib requested questions be posted there instead of in issues.

Collapse
 
jacoby profile image
Dave Jacoby

SO: I go back and search, but between the attitude (👎) and the large body of answered questions (👍), I rarely ask new questions anymore.

Indent Styles: There are nine distinct styles in the "Indentation Style" Wikipedia page. I suspect that, until we can generate and compile flowcharts, or can explain the problem and have Alexa code it for us, how we handle braces will be a bone of contention.

And, esp. if your repo had a perltidyrc in it, as some do, I'd try to conform to your style before sending.