Thread (39 messages) 39 messages, 5 authors, 2024-10-25
STALE616d
Revisions (3)
  1. v1 [diff vs current]
  2. v2 current
  3. v3 [diff vs current]

[PATCH v2 1/3] clang-format: change column limit to 96 characters

From: Karthik Nayak <hidden>
Date: 2024-10-10 17:59:17
Subsystem: clang-format file, the rest · Maintainers: Miguel Ojeda, Linus Torvalds

The current value for the column limit is set to 80. While this is as
expected, we often prefer readability over this strict limit. This means
it is common to find code which extends over 80 characters. So let's
change the column limit to be 96 instead. This provides some slack so we
can ensure readability takes preference over the 80 character hard
limit.

Signed-off-by: Karthik Nayak <redacted>
---
 .clang-format | 5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)
diff --git a/.clang-format b/.clang-format
index 41969eca4b..684ab32d28 100644
--- a/.clang-format
+++ b/.clang-format
@@ -12,7 +12,10 @@ UseTab: Always
 TabWidth: 8
 IndentWidth: 8
 ContinuationIndentWidth: 8
-ColumnLimit: 80
+
+# While we recommend keeping column limit to 80, we want to also provide
+# some slack to maintain readability.
+ColumnLimit: 96
 
 # C Language specifics
 Language: Cpp
-- 
2.47.0
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help