All of lore.kernel.org
 help / color / mirror / Atom feed
From: Randy Dunlap <rdunlap@xenotime.net>
To: Linux Kernel Mailing List <linux-kernel@vger.kernel.org>,
	Linus Torvalds <torvalds@linux-foundation.org>
Cc: Antonio Ospite <ospite@studenti.unina.it>
Subject: [PATCH 4/8] Documentation: update CodingStyle use of braces
Date: Fri, 04 Nov 2011 11:22:19 -0700	[thread overview]
Message-ID: <4EB42D5B.6050201@xenotime.net> (raw)
In-Reply-To: <4EB423D8.9030102@xenotime.net>

From: Antonio Ospite <ospite@studenti.unina.it>

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@studenti.unina.it>
Signed-off-by: Randy Dunlap <rdunlap@xenotime.net>
---
 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();

  parent reply	other threads:[~2011-11-04 18:23 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <4EB423D8.9030102@xenotime.net>
2011-11-04 18:22 ` [PATCH 2/8] Documentation: thinkpad-acpi grammo fixes Randy Dunlap
2011-11-04 18:22 ` [PATCH 3/8] Documentation: fix inotify source file paths Randy Dunlap
2011-11-04 18:22 ` Randy Dunlap [this message]
2011-11-04 18:22 ` [PATCH 5/8] Documentation: HFS is orphaned Randy Dunlap
2011-11-04 18:22 ` [PATCH 6/8] Documentation: Computone ip2 " Randy Dunlap
2011-11-04 18:22 ` [PATCH 7/8] Documentation: fix leds-class.txt duplicated word Randy Dunlap
2011-11-04 18:22 ` [PATCH 8/8] Documentation: drop as block elevator reference in switching-sched.txt Randy Dunlap

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=4EB42D5B.6050201@xenotime.net \
    --to=rdunlap@xenotime.net \
    --cc=linux-kernel@vger.kernel.org \
    --cc=ospite@studenti.unina.it \
    --cc=torvalds@linux-foundation.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.