tabs/spaces/braces? "The 100% Correct Coding Style Guide"

Started by Darren Dirt, April 04, 2017, 12:30:51 PM

Previous topic - Next topic

Darren Dirt

_____________________

Strive for progress. Not perfection.
_____________________

Mr. Analog

By Grabthar's Hammer

Tom

I was reading into code style/standards for work. One of my previous projects. Turns out, theres an actual real scientific study on CamelCase vs snake_case. snake_case wins. Turns out its the most like you'd read text, so you spend less time parsing and more time skimming like you'd normally do when reading. So you spend less time and less effort reading through code.

And I loathe languages that FORCE you into their edict. Spaces ARE NOT significant. Ugh. That said, I do LOVE context, and using lots of vertical white space and some horizontal white space can make code MUCH easier to read. so braces on new lines everywhere, spaces after keywords, etc. But a language that forces its idea of indentation and doesn't have braces is probably about the /worst/ for me in terms of being able to read it. Theres little to no context between statements there (I'm looking at you python >:( ) so I find it very hard to read.
<Zapata Prime> I smell Stanley... And he smells good!!!

Darren Dirt

IDK why but I always hated syntax:
"variable = value"
that extra whitespace around the "half mesh" irks me something fierce.

^ check linky; programming language DESIGN can be hilarious fun! ^
_____________________

Strive for progress. Not perfection.
_____________________