[merged] documentation-codingstyle-flesh-out-if-else-examples.patch removed from -mm tree

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



The patch titled
     Documentation/CodingStyle: flesh out if-else examples
has been removed from the -mm tree.  Its filename was
     documentation-codingstyle-flesh-out-if-else-examples.patch

This patch was dropped because it was merged into mainline or a subsystem tree

The current -mm tree may be found at http://userweb.kernel.org/~akpm/mmotm/

------------------------------------------------------
Subject: Documentation/CodingStyle: flesh out if-else examples
From: Harry Wei <jiaweiwei.xiyou@xxxxxxxxx>

There is a missing case for "Chapter 3: Placing Braces and Spaces".  We
often know we should not use braces where a single statement.  The first
case is:

	if (condition)
		action();

Another case is:

	if (condition)
		do_this();
	else
		do_that();

However, I can not find a description of the second case.

Signed-off-by: Harry Wei <harryxiyou@xxxxxxxxx>
Cc: Randy Dunlap <randy.dunlap@xxxxxxxxxx>
Signed-off-by: Andrew Morton <akpm@xxxxxxxxxxxxxxxxxxxx>
---

 Documentation/CodingStyle |    7 +++++++
 1 file changed, 7 insertions(+)

diff -puN Documentation/CodingStyle~documentation-codingstyle-flesh-out-if-else-examples Documentation/CodingStyle
--- a/Documentation/CodingStyle~documentation-codingstyle-flesh-out-if-else-examples
+++ a/Documentation/CodingStyle
@@ -168,6 +168,13 @@ Do not unnecessarily use braces where a 
 if (condition)
 	action();
 
+and
+
+if (condition)
+	do_this();
+else
+	do_that();
+
 This does not apply if one branch of a conditional statement is a single
 statement. Use braces in both branches.
 
_

Patches currently in -mm which might be from jiaweiwei.xiyou@xxxxxxxxx are

origin.patch

--
To unsubscribe from this list: send the line "unsubscribe mm-commits" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Kernel Newbies FAQ]     [Kernel Archive]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [Bugtraq]     [Photo]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]

  Powered by Linux