Use DataflowResultsCursor instead of FlowAtLocation #62315
Labels
A-MIR
Area: Mid-level IR (MIR) - https://blog.rust-lang.org/2016/04/19/MIR.html
C-cleanup
Category: PRs that clean code up or issues documenting cleanup.
T-compiler
Relevant to the compiler team, which will review and decide on the PR/issue.
#61922 introduced
DataflowResultsCursor
, which provides a stateful caching interface atopFlowAtLocation
.It would be better to use
DataflowResultsCursor
from more places, both because it's a more convenient / less error-prone interface, and because it's best to have more than one code path exercising the same code. It's also awkward trying to support both interfaces at once (the cursor implementation would be cleaner if we didn't have to).The main drawback to using it is that there will be extra state/branching in places where we don't need it.
cc @eddyb who asked me to open this, and (along with @nikomatsakis) helped provide inspiration for
DataflowResultsCursor
cc @ecstatic-morse @pnkfelix
The text was updated successfully, but these errors were encountered: