================
@@ -8435,6 +8435,20 @@ TEST_F(FormatTest, 
BreakConstructorInitializersAfterColon) {
       "  : public aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa,\n"
       "    public bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb {};",
       Style);
+  FormatStyle Tabbed = getLLVMStyleWithColumns(42);
+  Tabbed.IndentWidth = 4;
+  Tabbed.TabWidth = 4;
+  Tabbed.UseTab = FormatStyle::UT_AlignWithSpaces;
+  verifyFormat("class Foo : public aaaaaaaaa,\n"
+               "            protected bbbbbbbbb,\n"
+               "            private cccccccccc,\n"
+               "            dddddddddd {};",
+               Tabbed);
+  verifyFormat("struct S {\n"
+               "\tclass Foo : public aaaaaaaaa,\n"
+               "\t            private bbbbbbbbb {};\n"
+               "};",
+               Tabbed);
----------------
zeule wrote:

I understand that that is the current behaviour, thank you. It is just the 
documentation text which is confusing to me.

Maybe something like the following would be self describing?
```c++
enum BreakBehavior {No, Allow, Force};
enum BreakPoisition {Before, After};
struct  BreakElement {
    BreakBehavior behavior;
    BreakPoisition position;
};
struct BreakInheritanceList {
    BreakElement colon;
    BreakElement comma;
};
```

https://github.com/llvm/llvm-project/pull/189218
_______________________________________________
cfe-commits mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to