================ @@ -4811,8 +4813,11 @@ void UnwrappedLineParser::readToken(int LevelDifference) { (!Style.isVerilog() || Keywords.isVerilogPPDirective(*Tokens->peekNextToken())) && FirstNonCommentOnLine) { - distributeComments(Comments, FormatTok); - Comments.clear(); + + if (!UnbracedBodyDepth) { + distributeComments(Comments, FormatTok); + Comments.clear(); + } ---------------- owenca wrote:
```suggestion if (UnbracedBodyDepth == 0) { distributeComments(Comments, FormatTok); Comments.clear(); } ``` https://github.com/llvm/llvm-project/pull/94776 _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits