aeft wrote:

> If we reuse `ExpireFact`, it would need to carry both an optional `LoanID` 
> and an optional `OriginID`, and the transfer functions would need to branch 
> on which one is present. That feels a bit awkward with the current CRTP 
> dispatch where each fact kind maps to one transfer function.

@usx95 @Xazax-hun  Thanks for the feedback! I updated to only expire the 
outermost origin and accept the multi-level pointer case as a known limitation 
(with a FIXME noting it needs flow-sensitive origin aliasing).

Regarding reusing `ExpireFact`, they target fundamentally different entities 
(Loan vs Origin) with different transfer semantics (`ExpireFact` is no-op in 
dataflow). To reuse it, `ExpireFact` would need to hold either a `LoanID` or an 
`OriginID`, and transfer functions would branch on which is present. I think 
separate fact kinds are cleaner here, but happy to go with reuse if you prefer.

https://github.com/llvm/llvm-project/pull/182368
_______________________________________________
cfe-commits mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to