I’m currently working on a new parser package that will provide code analysis as it runs, part of which will be formatting hints. My hunting hasn’t found anything concrete so I’m looking for a bit of feedback on what are the key punctuation guidelines to be followed.
From the style guide in the docs we have
- use ! for modifying functions
- modules/types use camel casing
- functions use lowercase
- Don’t parenthesize conditions
And in addition
- 4 space indent for blocks (except modules)
- Spaces following commas (perhaps not when inside curly braces?)
- Spaces surround operators except powers, type/subtype declarations, unary ops, division, powers and dots
- No spaces on the inside edge of brackets
Any suggestions would be much appreciated