Commit 381b445
committed
Auto merge of rust-lang#77274 - tmiasko:liveness-cnd, r=lcnr
Liveness refactoring continued
* Move body_owner field from IrMaps to Liveness (the only user of the field).
* Use upvars instead of FnKind to check for closures (avoids FnKind, will be useful when checking all bodies, not just fns).
* Use visit_param to add variables corresponding to params.
* Store upvars_mentioned inside Liveness struct.
* Inline visitor implementation for IrMaps, avoiding unnecessary indirection.
* Test interaction with automatically_derived attribute (not covered by any of existing tests).
No functional changes intended.File tree
3 files changed
+244
-218
lines changed- compiler/rustc_passes/src
- src/test/ui/liveness
3 files changed
+244
-218
lines changed
0 commit comments