MyDeveloperDay added a comment. However if we add
AllowShortBlocksOnASingleLine : Always then it will be class Foo { foo() { if (x) bar(); if (x) { bar(); } } }; but if we set BasedOnStyle: LLVM AllowShortIfStatementsOnASingleLine: Never ColumnLimit: 80 AllowShortBlocksOnASingleLine : Always we get class Foo { foo() { if (x) bar(); if (x) { bar(); } } }; which feels like `if(x){ bar(); }` is primarily controlled by `AllowShortBlocksOnASingleLine` i.e. setting it to `Never` will override the `AllowShortIfStatementsOnASingleLine` setting for if statements with braces. However if `AllowShortBlocksOnASingleLine` is `Always` then if `AllowShortIfStatementsOnASingleLine` is set to `Never` then it wins. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D114521/new/ https://reviews.llvm.org/D114521 _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits