[clang-tools-extra] [clang-tidy] Fix false positive for generic lambda parameters in readability-non-const-parameter (PR #179051)

via cfe-commits cfe-commits at lists.llvm.org
Thu Feb 5 07:09:06 PST 2026


================
@@ -224,6 +224,9 @@ void NonConstParameterCheck::markCanNotBeConst(const Expr *E,
   } else if (const auto *ILE = dyn_cast<InitListExpr>(E)) {
     for (unsigned I = 0U; I < ILE->getNumInits(); ++I)
       markCanNotBeConst(ILE->getInit(I), true);
+  } else if (const auto *UCE = dyn_cast<CXXUnresolvedConstructExpr>(E)) {
----------------
EugeneZelenko wrote:

```suggestion
  } else if (dyn_cast<CXXUnresolvedConstructExpr>(E)) {
```

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


More information about the cfe-commits mailing list