Title: [285601] trunk
- Revision
- 285601
- Author
- [email protected]
- Date
- 2021-11-10 11:37:36 -0800 (Wed, 10 Nov 2021)
Log Message
Coding style for inner namespaces is should be simplified to not indented
https://bugs.webkit.org/show_bug.cgi?id=232073
Patch by Kimmo Kinnunen <[email protected]> on 2021-11-10
Reviewed by Antti Koivisto.
.:
* .clang-format:
Do not indent contents of inner namespaces, match current code.
Websites/webkit.org:
* code-style.md:
Simplify coding style to match the existing code: contents of inner namespaces
should not be indented.
Modified Paths
Diff
Modified: trunk/.clang-format (285600 => 285601)
--- trunk/.clang-format 2021-11-10 19:37:32 UTC (rev 285600)
+++ trunk/.clang-format 2021-11-10 19:37:36 UTC (rev 285601)
@@ -79,7 +79,7 @@
MacroBlockBegin: ''
MacroBlockEnd: ''
MaxEmptyLinesToKeep: 1
-NamespaceIndentation: Inner
+NamespaceIndentation: None
ObjCBlockIndentWidth: 4
ObjCSpaceAfterProperty: true
ObjCSpaceBeforeProtocolList: true
Modified: trunk/ChangeLog (285600 => 285601)
--- trunk/ChangeLog 2021-11-10 19:37:32 UTC (rev 285600)
+++ trunk/ChangeLog 2021-11-10 19:37:36 UTC (rev 285601)
@@ -1,3 +1,13 @@
+2021-11-10 Kimmo Kinnunen <[email protected]>
+
+ Coding style for inner namespaces is should be simplified to not indented
+ https://bugs.webkit.org/show_bug.cgi?id=232073
+
+ Reviewed by Antti Koivisto.
+
+ * .clang-format:
+ Do not indent contents of inner namespaces, match current code.
+
2021-11-09 J Pascoe <[email protected]>
Add j_pascoe to contributors.json
Modified: trunk/Websites/webkit.org/ChangeLog (285600 => 285601)
--- trunk/Websites/webkit.org/ChangeLog 2021-11-10 19:37:32 UTC (rev 285600)
+++ trunk/Websites/webkit.org/ChangeLog 2021-11-10 19:37:36 UTC (rev 285601)
@@ -1,3 +1,14 @@
+2021-11-10 Kimmo Kinnunen <[email protected]>
+
+ Coding style for inner namespaces is should be simplified to not indented
+ https://bugs.webkit.org/show_bug.cgi?id=232073
+
+ Reviewed by Antti Koivisto.
+
+ * code-style.md:
+ Simplify coding style to match the existing code: contents of inner namespaces
+ should not be indented.
+
2021-11-04 Ryan Haddad <[email protected]>
Add Monterey to WebKit Build Archives page
Modified: trunk/Websites/webkit.org/code-style.md (285600 => 285601)
--- trunk/Websites/webkit.org/code-style.md 2021-11-10 19:37:32 UTC (rev 285600)
+++ trunk/Websites/webkit.org/code-style.md 2021-11-10 19:37:36 UTC (rev 285601)
@@ -22,7 +22,7 @@
}
```
-[](#indentation-namespace) The contents of an outermost `namespace` block (and any nested namespaces with the same scope) should not be indented. The contents of other nested namespaces should be indented.
+[](#indentation-namespace) The contents of namespaces should not be indented.
###### Right:
@@ -36,7 +36,12 @@
};
namespace NestedNamespace {
+
+class OtherDocument {
+ OtherDocument();
...
+};
+
}
} // namespace WebCore
@@ -49,9 +54,31 @@
...
}
+namespace NestedNamespace {
+
+OtherDocument::OtherDocument()
+{
+ ...
+}
+
+} // namespace NestedNamespace
+
} // namespace WebCore
```
+###### Right:
+
+```cpp
+// PrivateClickMeasurementDatabase.h
+namespace WebKit::PCM {
+
+class Database {
+ ...
+};
+
+} // namespace WebKit::PCM
+```
+
###### Wrong:
```cpp
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes