Skip to content

Commit

Permalink
add spacing rule for opening/closin punctuation
Browse files Browse the repository at this point in the history
  • Loading branch information
remicollet committed Oct 21, 2016
1 parent 714bc0a commit 13278c5
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions source/codingstandards.rst
Original file line number Diff line number Diff line change
Expand Up @@ -21,8 +21,10 @@ Spacing

We've adopted "french spacing" rules in the code. The rule is:

* for *simple* punctuation (``,``, ``.``): use *one space after* the punctuation sign;
* for *double* punctuation (``!``, ``?``, ``:``): use *one space after and one space before* the punctuation sign.
* for *simple* punctuation (``,``, ``.``): use *one space after* the punctuation sign
* for *double* punctuation (``!``, ``?``, ``:``): use *one space after and one space before* the punctuation sign
* for *opening* punctuation (``(``, ``{``, ``[``): use *one space before* the punctuation sign
* for *closing* punctuation ( ``)``, ``}``, ``]``): use *one space after* the punctuation sign, excepted for line end, when followed by a semi-colon (``;``)

Of course, this rules only aplies on the source code, not on the strings (translatable strings, comments, ...)!

Expand Down

0 comments on commit 13278c5

Please sign in to comment.