================
@@ -107,19 +107,21 @@ void MissingStdForwardCheck::registerMatchers(MatchFinder
*Finder) {
auto CapturedInLambda = hasDeclContext(cxxRecordDecl(
isLambda(),
- hasParent(lambdaExpr(forCallable(equalsBoundNode("func")),
- anyOf(CapturedInCaptureList, CapturedInBody)))));
+ hasAncestor(lambdaExpr(forCallable(equalsBoundNode("func")),
+ anyOf(CapturedInCaptureList, CapturedInBody)))));
----------------
HerrCai0907 wrote:
I looks make no sense to use `hasAncestor` for `cxxRecordDecl` to find
`lambdaExpr`. lambda auto generated structure should be always a child of
`lambdaExpr`.
https://github.com/llvm/llvm-project/pull/178651
_______________________________________________
cfe-commits mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits