]> git.lizzy.rs Git - rust.git/blobdiff - compiler/rustc_mir_transform/src/generator.rs
Rollup merge of #106441 - mllken:abstract-socket-noref, r=joshtriplett
[rust.git] / compiler / rustc_mir_transform / src / generator.rs
index c08593afe9d88ff900b6c116ffcd8183cc0b89d4..c097af6161159a7fcec85b6b0bb69a3605fcb8e9 100644 (file)
@@ -490,7 +490,7 @@ fn locals_live_across_suspend_points<'tcx>(
 
     // Calculate when MIR locals have live storage. This gives us an upper bound of their
     // lifetimes.
-    let mut storage_live = MaybeStorageLive::new(always_live_locals.clone())
+    let mut storage_live = MaybeStorageLive::new(std::borrow::Cow::Borrowed(always_live_locals))
         .into_engine(tcx, body_ref)
         .iterate_to_fixpoint()
         .into_results_cursor(body_ref);