Thread (8 messages) flat view 8 messages, 6 authors, 2016-06-15

Re: [PATCH] Add Documentation/CodingStyle

From: Jon Loeliger <hidden>
Date: 2016-06-15 22:43:48

Possibly related (same subject, not in this thread)

On Tue, 2007-11-06 at 17:17, Johannes Schindelin wrote:
+
+ - Do not use curly brackets unnecessarily.  I.e.
+
+	if (bla) {
+		x = 1;
+	}
In my opinion, I think this is a bad guideline.
+   is frowned upon.  A gray area is when the statement extends over a
+   few lines, and/or you have a lengthy comment atop of it.
Or if it is some macro, or any number of vague problem areas.

Again, in my opinion, one should always take the safer
defensive programming tactic and always use braces.
Having them really never produces errors, while omitting
them is often error prone.

Yes, I know that is not a popular opinion by example,
but I'm still allowed to state it. :-)
Feel free to ignore me as well. :-)

jdl
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help