4 ms·
Personally, it's not a significant issue, but it is a preference. Do you indent code when coding with braces? How anal are you about keeping your code formatt
by CatMtKing 13y ago
Personally, it's not a significant issue, but it is a preference. Do you indent code when coding with braces? How anal are you about keeping your code formatted consistently (i.e. spaces after operators)?
- moron4hire 13y agoSometimes, not always. I'm likely to put a one-line getter/setter on one line. I use formatter tools to do most of the formatting. It's nice to have formatted code, but I'm not fastidious about it. It's bound to Ctrl+K, Ctrl+D in Visual Studio. I prefix it to Ctrl+S out of habit. But if the automatic formatter can't take care of it, I don't bother changing anything. Simplicity and consistency are more important than "having my way". Code should be readable, which is a human issue. As such, I think it's always going to have edge cases where "breaking the rules" is appropriate. EDIT: Come to think of it, I often use the formatting as a pre-check before compiling. If the formatter doesn't format the code as I expect it to, it means I've screwed up a block somewhere. That's pretty much it for me.
- Dobbs 13y agoThis is 100% a non-issue in go. gofmt will automatically make all of your code look just like how everyone else writes it. In addition most editors have plugins for automatic gofmt on save.