Skip to content

Commit dff4982

Browse files
Alan-CoxLinus Torvalds
authored andcommitted
CodingStyle: relax the 80-cole rule
I would suggest this change to make CodingStyle properly reflect the style used by the kernel, rather than the current wording which is wishful thinking and misleading, and comes from the same school of thought that gets off on prescriptive grammar, latin and comp.std.c Signed-off-by: Alan Cox <alan@redhat.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
1 parent 9c6cdad commit dff4982

1 file changed

Lines changed: 5 additions & 2 deletions

File tree

‎Documentation/CodingStyle‎

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -77,12 +77,15 @@ Get a decent editor and don't leave whitespace at the end of lines.
7777
Coding style is all about readability and maintainability using commonly
7878
available tools.
7979

80-
The limit on the length of lines is 80 columns and this is a hard limit.
80+
The limit on the length of lines is 80 columns and this is a strongly
81+
preferred limit.
8182

8283
Statements longer than 80 columns will be broken into sensible chunks.
8384
Descendants are always substantially shorter than the parent and are placed
8485
substantially to the right. The same applies to function headers with a long
85-
argument list. Long strings are as well broken into shorter strings.
86+
argument list. Long strings are as well broken into shorter strings. The
87+
only exception to this is where exceeding 80 columns significantly increases
88+
readability and does not hide information.
8689

8790
void fun(int a, int b, int c)
8891
{

0 commit comments

Comments
 (0)