This commit is contained in:
Daniel Bader
2017-05-24 22:12:06 -07:00
parent 26b0907345
commit d888affd7b
+1 -1
View File
@@ -371,7 +371,7 @@ result = some_function_that_takes_arguments(
<h2 id="break-before-or-after-binary-operator">Should a line break before or after a binary operator?</h2>
<p>For decades the recommended style has been to break after binary operators. However, recent reseach unearthed recommendations by Donald Knuth to break <em>before</em> binary operators, in his writings about typesetting <a href="#fn4" class="footnoteRef" id="fnref4"><sup>4</sup></a>. Therefore it is permissible to break before or after a binary operator, as long as the convention is consistent locally. For new code Knuth's style is suggested.</p>
<p>For decades the recommended style has been to break after binary operators. However, recent research unearthed recommendations by Donald Knuth to break <em>before</em> binary operators, in his writings about typesetting <a href="#fn4" class="footnoteRef" id="fnref4"><sup>4</sup></a>. Therefore it is permissible to break before or after a binary operator, as long as the convention is consistent locally. For new code Knuth's style is suggested.</p>
<p>Some examples of code breaking before binary Boolean operators:<p>