[clang] [LifetimeSafety] Detect use-after-return (PR #165370)
Kashika Akhouri via cfe-commits
cfe-commits at lists.llvm.org
Tue Nov 18 07:10:26 PST 2025
================
@@ -53,6 +53,17 @@ struct Lattice {
}
};
+static SourceLocation
+GetFactLoc(llvm::PointerUnion<const UseFact *, const OriginEscapesFact *> F) {
+ if (const auto *UF = F.dyn_cast<const UseFact *>())
+ return UF->getUseExpr()->getExprLoc();
+
----------------
kashika0112 wrote:
Done
https://github.com/llvm/llvm-project/pull/165370
More information about the cfe-commits
mailing list