Details
Diff Detail
- Repository
- rG LLVM Github Monorepo
Event Timeline
This fixes the issue with exponential traversal times for deeply nested lambdas. Please add a test though. For example, this one:
void f() { [] { [] { [] { [] { [] { [] { [] { [] { [] { [] { [] { [] { [] { [] { [] { [] { [] { [] { [] { [] { [] { [] { [] { [] { [] { [] { [] { [] { [] { }(); }(); }(); }(); }(); }(); }(); }(); }(); }(); }(); }(); }(); }(); }(); }(); }(); }(); }(); }(); }(); }(); }(); }(); }(); }(); }(); }(); }(); }
Thanks for the prompt fix, btw!
clang/include/clang/AST/RecursiveASTVisitor.h | ||
---|---|---|
2064 | Please specify the type explicitly here. |
clang/include/clang/AST/RecursiveASTVisitor.h | ||
---|---|---|
2063–2065 | This is incorrectly skipping the bodies of all other lambda member functions (default ctor, copy ctor, destructor, implicit conversion to function pointer type), not only the "body" of the lambda itself (the definition of the operator()). |
clang/include/clang/AST/RecursiveASTVisitor.h | ||
---|---|---|
2063–2065 | Please see https://reviews.llvm.org/D95644. |
Since the 12 branch has been cut, I've added a blocking bug to get this fixed in some form: https://bugs.llvm.org/show_bug.cgi?id=48935
@rsmith I've assigned it to you to make a call about whether to cherrypick this patch, this patch+followup, or revert the original change on the branch.
(@steveire is a revert really an option here, or is there already more stuff relying on this?)
Please specify the type explicitly here.