Greatly simplify lifetime captures in edition 2024

This commit is contained in:
Michael Goulet
2025-02-20 18:58:46 +00:00
parent 46420c9607
commit 12e3911d81
84 changed files with 223 additions and 294 deletions

View File

@@ -138,7 +138,7 @@ impl SsaLocals {
pub(super) fn assignments<'a, 'tcx>(
&'a self,
body: &'a Body<'tcx>,
) -> impl Iterator<Item = (Local, &'a Rvalue<'tcx>, Location)> + 'a {
) -> impl Iterator<Item = (Local, &'a Rvalue<'tcx>, Location)> {
self.assignment_order.iter().filter_map(|&local| {
if let Set1::One(DefLocation::Assignment(loc)) = self.assignments[local] {
let stmt = body.stmt_at(loc).left()?;