[clang] [llvm] [LifetimeSafety] Add lifetimebound inference for std::make_unique (PR #191632)
Utkarsh Saxena via cfe-commits
cfe-commits at lists.llvm.org
Thu Apr 16 03:44:51 PDT 2026
================
@@ -484,7 +484,8 @@ void FactsGenerator::VisitCXXOperatorCallExpr(const CXXOperatorCallExpr *OCE) {
hasOrigins(OCE->getArg(0)->getType())) {
// Pointer-like types: assignment inherently propagates origins.
QualType LHSTy = OCE->getArg(0)->getType();
- if (LHSTy->isPointerOrReferenceType() || isGslPointerType(LHSTy)) {
+ if (LHSTy->isPointerOrReferenceType() || isGslPointerType(LHSTy) ||
+ isGslOwnerType(LHSTy)) {
----------------
usx95 wrote:
> origin propagation should happen regardless in all cases (if there is an origin).
I will defer this to a separate PR.
https://github.com/llvm/llvm-project/pull/191632
More information about the cfe-commits
mailing list