From ee41c1904a39d485b11672064f67ffe0236105fc Mon Sep 17 00:00:00 2001 From: Antoni Boucher Date: Tue, 2 Jul 2024 12:33:09 -0400 Subject: [PATCH] Update to nightly-2024-07-02 --- rust-toolchain | 2 +- src/back/lto.rs | 7 ++++--- 2 files changed, 5 insertions(+), 4 deletions(-) diff --git a/rust-toolchain b/rust-toolchain index 7a1806fe3c76..3c83f4b4608d 100644 --- a/rust-toolchain +++ b/rust-toolchain @@ -1,3 +1,3 @@ [toolchain] -channel = "nightly-2024-06-18" +channel = "nightly-2024-07-02" components = ["rust-src", "rustc-dev", "llvm-tools-preview"] diff --git a/src/back/lto.rs b/src/back/lto.rs index 4b31bfac5dd7..19964176bcbd 100644 --- a/src/back/lto.rs +++ b/src/back/lto.rs @@ -364,7 +364,8 @@ pub(crate) fn run_thin( cached_modules: Vec<(SerializedModule, WorkProduct)>, ) -> Result<(Vec>, Vec), FatalError> { let dcx = cgcx.create_dcx(); - let lto_data = prepare_lto(cgcx, &dcx)?; + let dcx = dcx.handle(); + let lto_data = prepare_lto(cgcx, dcx)?; /*let symbols_below_threshold = symbols_below_threshold.iter().map(|c| c.as_ptr()).collect::>();*/ if cgcx.opts.cg.linker_plugin_lto.enabled() { @@ -375,7 +376,7 @@ pub(crate) fn run_thin( } thin_lto( cgcx, - &dcx, + dcx, modules, lto_data.upstream_modules, lto_data.tmp_path, @@ -425,7 +426,7 @@ pub(crate) fn prepare_thin( /// they all go out of scope. fn thin_lto( cgcx: &CodegenContext, - _dcx: &DiagCtxt, + _dcx: DiagCtxtHandle<'_>, modules: Vec<(String, ThinBuffer)>, serialized_modules: Vec<(SerializedModule, CString)>, tmp_path: TempDir,