about summary refs log tree commit diff
diff options
context:
space:
mode:
-rw-r--r--src/driver/aot.rs2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/driver/aot.rs b/src/driver/aot.rs
index 5e1e1c81d26..0faf1221c83 100644
--- a/src/driver/aot.rs
+++ b/src/driver/aot.rs
@@ -85,7 +85,7 @@ fn reuse_workproduct_for_cgu(
     work_products: &mut FxHashMap<WorkProductId, WorkProduct>,
 ) -> CompiledModule {
     let mut object = None;
-    let work_product = cgu.work_product(tcx);
+    let work_product = cgu.previous_work_product(tcx);
     if let Some(saved_file) = &work_product.saved_file {
         let obj_out =
             tcx.output_filenames(()).temp_path(OutputType::Object, Some(cgu.name().as_str()));