[clang] [clang-format] Fix anonymous reference parameter with default value (PR #86254)

Björn Schäpers via cfe-commits cfe-commits at lists.llvm.org
Mon Mar 25 13:04:21 PDT 2024


================
@@ -19056,6 +19056,9 @@ TEST_F(FormatTest, AlignConsecutiveDeclarations) {
   verifyFormat("int    a(int x);\n"
                "double b();",
                Alignment);
+  verifyFormat("int    a(const Test & = Test());\n"
----------------
HazardyKnusperkeks wrote:

I wanted to see a version where the arguments are aligned, you need a break in the argument list. Either by providing more arguments, or (preferred) by using a reduced `ColumnLimit` for that test.

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


More information about the cfe-commits mailing list