================
@@ -134,6 +136,10 @@ class LifetimeChecker {
if (PVD->hasAttr<LifetimeBoundAttr>()) {
// Track that this lifetimebound parameter correctly escapes.
VerifiedLiftimeboundEscapes.insert(PVD);
+ if (auto [UnannotatedFDecl, Scope] =
+ getUnannotatedDeclBestMatch(cast<FunctionDecl>(FD), PVD);
+ UnannotatedFDecl)
+ DeclarationsToAnnotate.try_emplace(UnannotatedFDecl, Scope);
----------------
usx95 wrote:
This is largely a policy change about where to put the annotation and not about
escape analysis itself. I would prefer to do this separately as part of
`reportMisplacedLifetimebound` and not `checkAnnotations` (which checks for
escape semantics).
https://github.com/llvm/llvm-project/pull/197753
_______________________________________________
cfe-commits mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits