[clang-tools-extra] [clang-tidy] Add support for struct initialization in `bugprone-argument-comment` (PR #171757)

via cfe-commits cfe-commits at lists.llvm.org
Wed Dec 10 22:49:40 PST 2025


================
@@ -366,6 +549,12 @@ void ArgumentCommentCheck::check(const MatchFinder::MatchResult &Result) {
         Result.Context, Construct->getConstructor(),
         Construct->getParenOrBraceRange().getBegin(),
         llvm::ArrayRef(Construct->getArgs(), Construct->getNumArgs()));
+    return;
+  }
+
+  if (const auto *InitList = dyn_cast<InitListExpr>(E)) {
+    checkInitList(Result.Context, InitList);
+    return;
----------------
zeyi2 wrote:

Fixed, thanks :)

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


More information about the cfe-commits mailing list