[clang] [clang-format] Add an option to control indentation of `export { ... }` (PR #110381)

Björn Schäpers via cfe-commits cfe-commits at lists.llvm.org
Thu Oct 24 11:31:14 PDT 2024


================
@@ -26588,10 +26613,7 @@ TEST_F(FormatTest, Cpp20ModulesSupport) {
                "  int foo;\n"
                "};",
                Style);
-  verifyFormat("export {\n"
-               "  int foo;\n"
-               "};",
-               Style);
+  verifyFormat("export { int foo; };", Style);
----------------
HazardyKnusperkeks wrote:

There should be an option to en/disable it, if it can be shared with other things, or be exclusively for export is to be discussed. I have no strong opinion, but would lean to an extra option, because someone will ask for it.

https://github.com/llvm/llvm-project/pull/110381


More information about the cfe-commits mailing list