[PATCH 4/8] Documentation: update CodingStyle use of braces

From: Randy Dunlap
Date: Fri Nov 04 2011 - 14:23:06 EST


From: Antonio Ospite <ospite@xxxxxxxxxxxxxxxxx>

After commit 38829dc highlight that if _only_one_ branch of a
conditional statement is a single statement, then braces are to be used
on both branches.

Signed-off-by: Antonio Ospite <ospite@xxxxxxxxxxxxxxxxx>
Signed-off-by: Randy Dunlap <rdunlap@xxxxxxxxxxxx>
---
Documentation/CodingStyle | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)

--- lnx1104.orig/Documentation/CodingStyle
+++ lnx1104/Documentation/CodingStyle
@@ -166,8 +166,8 @@ if (condition)
else
do_that();

-This does not apply if one branch of a conditional statement is a single
-statement. Use braces in both branches.
+This does not apply if only one branch of a conditional statement is a single
+statement; in the latter case use braces in both branches:

if (condition) {
do_this();
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/