Hacker News new | ask | show | jobs
by ArtB 4217 days ago
Formatting -IMHO- depends on context. I have one convention I generally use which is chaining methods together on one line, but when chaining together builder method call I make one line per call. That means the semantics not the syntactics of the code determine my formatting. For this reason I abhor auto formatting code unless it is currently like an unrecoverable mess (ie NO thoguht put into it, not just "not my style"). Honestly, put your curlies wherever you like them, then don't effect readability as much as lacking comments or convoluted flow.
1 comments

Thank you - go fmt sucks. I hate K&R parameter layout, and I hate long lines that scroll off to the right of the screen.
Yes, but it's nice to save my code and have it formatted "the official way". It gets old debating over which standard to use. Who cares what you like. Just pick a standard for every language and get used to it. It's really not that hard.