[clang] [LifetimeSafety] Add UseFacts for function arguments and assignment RHS (PR #180446)
Utkarsh Saxena via cfe-commits
cfe-commits at lists.llvm.org
Mon Feb 16 07:58:51 PST 2026
================
@@ -366,6 +366,7 @@ void FactsGenerator::VisitBinaryOperator(const BinaryOperator *BO) {
// result should have the same loans as the pointer operand.
if (BO->isCompoundAssignmentOp())
return;
+ handleUse(BO->getRHS());
----------------
usx95 wrote:
Sounds like a great idea to systematically move away from special casing `DeclRefExpr`.
I would prefer to do it in a separate PR though (https://github.com/llvm/llvm-project/pull/181693 in progress) as it involves changing a liveness, lot of tests which rely on `(void)view` being a use of `view`.
https://github.com/llvm/llvm-project/pull/180446
More information about the cfe-commits
mailing list