================
@@ -3168,6 +3173,25 @@ TEST_F(FormatTest, FormatsLabels) {
" g();\n"
" }\n"
"}");
+ verifyFormat("void func() {\n"
+ "label:\n"
+ " {\n"
+ " // Block\n"
+ " }\n"
+ "}");
+ verifyFormat("void func() {\n"
+ "label: // Comment\n"
+ " {\n"
+ " // Block\n"
+ " }\n"
+ "}");
+ verifyFormat("void func() {\n"
+ "label:\n"
+ " // Comment\n"
+ " {\n"
+ " // Block\n"
+ " }\n"
+ "}");
----------------
HazardyKnusperkeks wrote:
```suggestion
```
https://github.com/llvm/llvm-project/pull/197538
_______________________________________________
cfe-commits mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits