public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH] CodingStyle: Add information about trailing whitespace.
@ 2007-06-27 17:59 Josh Triplett
  2007-06-27 18:05 ` Chris Shoemaker
  2007-06-27 19:31 ` Andrew Morton
  0 siblings, 2 replies; 27+ messages in thread
From: Josh Triplett @ 2007-06-27 17:59 UTC (permalink / raw)
  To: linux-kernel; +Cc: akpm, josh

Signed-off-by: Josh Triplett <josh@kernel.org>
---
 Documentation/CodingStyle |   12 ++++++++++++
 1 files changed, 12 insertions(+), 0 deletions(-)

diff --git a/Documentation/CodingStyle b/Documentation/CodingStyle
index b49b92e..00bffa7 100644
--- a/Documentation/CodingStyle
+++ b/Documentation/CodingStyle
@@ -218,6 +218,18 @@ no space after the prefix increment & decrement unary operators:
 
 and no space around the '.' and "->" structure member operators.
 
+Do not leave trailing whitespace at the ends of lines.  Some editors with
+"smart" indentation will insert whitespace at the beginning of new lines as
+appropriate, so you can start typing the next line of code right away.
+However, some such editors do not remove the whitespace if you end up not
+putting a line of code there, such as if you leave a blank line.  As a result,
+you end up with lines containing trailing whitespace.
+
+Git will warn you about patches that introduce trailing whitespace, and can
+optionally strip the trailing whitespace for you; however, if applying a series
+of patches, this may make later patches in the series fail by changing their
+context lines.
+
 
 		Chapter 4: Naming
 
-- 
1.5.2.1



^ permalink raw reply related	[flat|nested] 27+ messages in thread

end of thread, other threads:[~2007-06-30  0:00 UTC | newest]

Thread overview: 27+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2007-06-27 17:59 [PATCH] CodingStyle: Add information about trailing whitespace Josh Triplett
2007-06-27 18:05 ` Chris Shoemaker
2007-06-27 18:17   ` Josh Triplett
2007-06-27 19:32     ` Chris Shoemaker
2007-06-27 22:18   ` Jan Engelhardt
2007-06-28  6:00     ` dave young
2007-06-28  6:08       ` Josh Triplett
2007-06-28  6:29         ` dave young
2007-06-28  6:52           ` Jan Engelhardt
2007-06-28  6:58             ` Josh Triplett
2007-06-28  7:08               ` Li Yang-r58472
2007-06-28  7:10                 ` Dave Young
2007-06-28  7:20                   ` Dave Young
2007-06-29  3:11                     ` [OT] Vim highlighting for trailing spaces Kyle Moffett
2007-06-29  7:39                       ` Jan Engelhardt
2007-06-29  7:53                         ` Josh Triplett
2007-06-29  8:01                           ` Jan Engelhardt
2007-06-29  8:42                             ` Josh Triplett
2007-06-29  9:21                               ` Björn Steinbrink
2007-06-29  9:26                                 ` Dave Young
2007-06-29 12:40                       ` Michael Tokarev
2007-06-29 12:49                         ` Dmitry Torokhov
2007-06-30  0:00                           ` Kyle Moffett
2007-06-29  2:03               ` [PATCH] CodingStyle: Add information about trailing whitespace Andy Isaacson
2007-06-27 19:31 ` Andrew Morton
2007-06-27 22:14   ` Jan Engelhardt
2007-06-27 22:14   ` Oleg Verych

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox