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 7d5592daac1..27adf6318e2 100644
--- a/src/driver/aot.rs
+++ b/src/driver/aot.rs
@@ -676,7 +676,7 @@ pub(crate) fn run_aot(
     .to_owned();
 
     let cgus = if tcx.sess.opts.output_types.should_codegen() {
-        tcx.collect_and_partition_mono_items(()).1
+        tcx.collect_and_partition_mono_items(()).codegen_units
     } else {
         // If only `--emit metadata` is used, we shouldn't perform any codegen.
         // Also `tcx.collect_and_partition_mono_items` may panic in that case.