Small style additions

9ed57feb334d3ac29a987a9595e1d82dca230e7c373224d7ca9525364dc2b5b4
Alexis Sellier committed ago 1 parent 56a00753
STYLE +5 -0
24 24
* Name fields after their role in the abstraction, not after an incidental implementation detail.
25 25
* Name callbacks after what the caller is asking them to do.
26 26
* When wrapping a lower-level operation, choose a name that distinguishes the wrapper from the operation it delegates to.
27 27
* Keep function names short, but not at the cost of hiding important context.
28 28
29 +
WHITESPACE
30 +
31 +
* Don't inline blocks like `if x { return true; }`, always return after `{`.
32 +
* Don't add a blank line after a closing `}` inside a function.
33 +
29 34
HELPERS
30 35
31 36
* Do not create small helper functions when they are only used in one place.
32 37
* Generally avoid one-line helpers, unless it's a complicated line.
33 38