[clang] [clang-format] Reorder TokenAnnotator::canBreakBefore (PR #119044)

Owen Pan via cfe-commits cfe-commits at lists.llvm.org
Sat Dec 7 23:29:57 PST 2024


================
@@ -9383,6 +9383,13 @@ TEST_F(FormatTest, AlignsAfterOpenBracket) {
       "        aaaaaaaaaaaaaaaaaaaa(aaaaaaaaaaaaaaaaa, aaaaaaaaaaaaaaaa)) &&\n"
       "    aaaaaaaaaaaaaaaa);",
       Style);
+  verifyFormat("void foo(\n"
+               "    void (*foobarpntr)(\n"
+               "        aaaaaaaaaaaaaaaaaa *,\n"
+               "        bbbbbbbbbbbbbb *,\n"
+               "        cccccccccccccccccccc *,\n"
+               "        dddddddddddddddddd *));",
----------------
owenca wrote:

We probably can do without this test, which would pass without this patch.

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


More information about the cfe-commits mailing list