[clang] [LifetimeSafety] Track origins for lifetimebound calls returning record types (PR #187917)

Utkarsh Saxena via cfe-commits cfe-commits at lists.llvm.org
Wed Mar 25 09:52:00 PDT 2026


================
@@ -662,7 +681,7 @@ void FactsGenerator::handleFunctionCall(const Expr *Call,
   auto IsArgLifetimeBound = [FD](unsigned I) -> bool {
     const ParmVarDecl *PVD = nullptr;
     if (const auto *Method = dyn_cast<CXXMethodDecl>(FD);
-        Method && Method->isInstance()) {
+        Method && Method->isInstance() && !isa<CXXConstructorDecl>(FD)) {
----------------
usx95 wrote:

Is this somehow related to https://github.com/llvm/llvm-project/issues/175898 ?

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


More information about the cfe-commits mailing list