[clang] [Lifetime Safety] Highlight lifetimebound calls in alias chain diagnostics (PR #206337)
Gábor Horváth via cfe-commits
cfe-commits at lists.llvm.org
Tue Jul 7 04:07:52 PDT 2026
================
@@ -30,6 +31,11 @@ namespace clang::lifetimes::internal {
using FactID = utils::ID<struct FactTag>;
+struct LifetimeBoundInfo {
+ const ParmVarDecl *Param = nullptr;
+ bool IsImplicitObject = false;
+};
----------------
Xazax-hun wrote:
There are a couple ways around this. The rest of the analysis is sometimes using a `PointerUnion<ParmVarDecl*, CXXMethodDecl*>` and the declaration to the method represents the implicit object parameter. Alternative design is an optional pointer and empty optional meaning not found and a non-empty null meaning the implicit this. Just some random ideas, no strong preference.
https://github.com/llvm/llvm-project/pull/206337
More information about the cfe-commits
mailing list