From 6fc19751d66e7e316b3763658fe9fd624a84ca6e Mon Sep 17 00:00:00 2001 From: Wouter Geraedts Date: Thu, 16 Jul 2026 14:41:37 +0200 Subject: [PATCH] Update to nightly-2026-07-15 --- cga_analysis/src/post_mono.rs | 17 +---------------- rust-toolchain.toml | 2 +- tests/ui-cargo/fail-blacklist/Cargo.stderr | 14 +++++++------- tests/ui-cargo/fail-embedded/Cargo.stderr | 12 ++++++------ tests/ui/large_std_process.stderr | 8 ++++---- 5 files changed, 19 insertions(+), 34 deletions(-) diff --git a/cga_analysis/src/post_mono.rs b/cga_analysis/src/post_mono.rs index f71a559..94506bb 100644 --- a/cga_analysis/src/post_mono.rs +++ b/cga_analysis/src/post_mono.rs @@ -306,22 +306,7 @@ impl<'b, 'a, 'tcx> PostMonoNode<'b, 'a, 'tcx> { debug!("ignoring call to non-constant function {func:?}"); return vec![]; }; - let mut instance = self.monomorphize_instance(pre_mono_call, generic_args, span); - - // Look for `::call` for some T. - // If T is a function type, the compiler synthesizes an impl, so we'll check - // the trait declaration in libcore which isn't what we want. Check if the - // function is annotated instead. - if let InstanceKind::Shim(ShimKind::FnPtr(_, ty) | ShimKind::FnPtrAddr(_, ty)) = instance.def - && let ty::FnDef(fn_item, fn_args) = ty.kind() - { - debug!("found function item {fn_item:?}"); - instance = self.monomorphize_instance(*fn_item, fn_args, span); - } - - // Double check if our instance is OK - - instance + self.monomorphize_instance(pre_mono_call, generic_args, span) } TerminatorKind::Drop { place, .. } => { let (ty, _) = self.monomorphize_args(place.ty(self.body, tcx)); diff --git a/rust-toolchain.toml b/rust-toolchain.toml index e2bc4fa..99be271 100644 --- a/rust-toolchain.toml +++ b/rust-toolchain.toml @@ -1,5 +1,5 @@ [toolchain] -channel = "nightly-2026-06-29" +channel = "nightly-2026-07-15" components = ["cargo", "llvm-tools", "rust-src", "rust-std", "rustc", "rustc-dev", "rustfmt", "clippy"] profile = "minimal" targets = ["thumbv8m.main-none-eabihf"] diff --git a/tests/ui-cargo/fail-blacklist/Cargo.stderr b/tests/ui-cargo/fail-blacklist/Cargo.stderr index 190dd10..7d7ca20 100644 --- a/tests/ui-cargo/fail-blacklist/Cargo.stderr +++ b/tests/ui-cargo/fail-blacklist/Cargo.stderr @@ -4,8 +4,8 @@ error: call to associated function `std::process::Command::new` which can panic 7 | let _ = std::process::Command::new("evil"); | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ | - = note: 14 different panics from this location - = note: backtrace (1 of 3843059837): + = note: 11 different panics from this location + = note: backtrace (1 of 1863650189): 0: std::rt::panic_fmt (called) 1: alloc::raw_vec::RawVec::::into_box (called) 2: std::vec::Vec::::into_boxed_slice (called) @@ -23,8 +23,8 @@ error: call to drop of `std::process::Command` which can panic 7 | let _ = std::process::Command::new("evil"); | ^ | - = note: 14 different panics from this location - = note: backtrace (1 of 3843090268): + = note: 11 different panics from this location + = note: backtrace (1 of 1863680573): 0: core::panicking::panic_nounwind_fmt (called) 1: >::get_unchecked_mut::precondition_check (called) 2: >::get_unchecked_mut (called) @@ -42,7 +42,7 @@ error: call to associated function `std::process::Command::new` which is blackli 7 | let _ = std::process::Command::new("evil"); | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ | - = note: 104 different blacklisted functions from this location + = note: 101 different blacklisted functions from this location = note: backtrace: 0: std::process::Command::new::<&str> (called) <-- 1: fail_blacklist::test (called) @@ -59,8 +59,8 @@ error: call to drop of `std::process::Command` which can call blacklisted functi 7 | let _ = std::process::Command::new("evil"); | ^ | - = note: 105 different blacklisted functions from this location - = note: backtrace (1 of 42160433): + = note: 101 different blacklisted functions from this location + = note: backtrace (1 of 20283553): 0: std::sys::fs::unix::debug_assert_fd_is_open (called) 1: ::drop (called) 2: drop of `std::os::fd::OwnedFd` (called) diff --git a/tests/ui-cargo/fail-embedded/Cargo.stderr b/tests/ui-cargo/fail-embedded/Cargo.stderr index 821312d..097fb4d 100644 --- a/tests/ui-cargo/fail-embedded/Cargo.stderr +++ b/tests/ui-cargo/fail-embedded/Cargo.stderr @@ -4,8 +4,8 @@ error: call to method `embassy_executor::Executor::run` which can panic 11 | #[embassy_executor::main] | ^^^^^^^^^^^^^^^^^^^^^^^^^ expanded from here | - = note: 13 different panics from this location - = note: backtrace (1 of 17249841): + = note: 10 different panics from this location + = note: backtrace (1 of 16511908): 0: core::panicking::panic_fmt (called) 1: core::result::unwrap_failed (called) 2: core::result::Result::, embassy_executor::SpawnError>::unwrap (called) @@ -25,9 +25,9 @@ error: call to function `embassy_rp::init` which can panic = note: 7 different panics from this location = note: backtrace (1 of 721): 0: core::panicking::panic_fmt (called) - 1: core::sync::atomic::compiler_fence (called) - 2: ::enable (called) - 3: embassy_rp::time_driver::init (called) + 1: core::sync::atomic::atomic_store:: (called) + 2: core::sync::atomic::Atomic::::store (called) + 3: embassy_rp::clocks::init (called) 4: embassy_rp::init (called) <-- 5: fail_embedded::____embassy_main_task::____embassy_main_task_inner_function::{closure#0} (called) 6: embassy_executor::raw::TaskStorage::<{async fn body of fail_embedded::____embassy_main_task::____embassy_main_task_inner_function()}>::poll (fn-ptr cast) @@ -166,7 +166,7 @@ error: call to associated function `embassy_time::Timer::after_secs` which can p 26 | Timer::after_secs(2).await; | ^^^^^^^^^^^^^^^^^^^^ | - = note: 14 different panics from this location + = note: 11 different panics from this location = note: backtrace (1 of 2): 0: core::panicking::panic_display::<&str> (called) 1: core::option::expect_failed (called) diff --git a/tests/ui/large_std_process.stderr b/tests/ui/large_std_process.stderr index b4d5c1e..4c9002d 100644 --- a/tests/ui/large_std_process.stderr +++ b/tests/ui/large_std_process.stderr @@ -4,8 +4,8 @@ error: call to associated function `std::process::Command::new` which can panic LL | let _ = std::process::Command::new("evil"); | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ | - = note: 14 different panics from this location - = note: backtrace (1 of 3843059837): + = note: 11 different panics from this location + = note: backtrace (1 of 1863650189): 0: std::rt::panic_fmt (called) 1: alloc::raw_vec::RawVec::::into_box (called) 2: std::vec::Vec::::into_boxed_slice (called) @@ -23,8 +23,8 @@ error: call to drop of `std::process::Command` which can panic LL | let _ = std::process::Command::new("evil"); | ^ | - = note: 14 different panics from this location - = note: backtrace (1 of 3843090268): + = note: 11 different panics from this location + = note: backtrace (1 of 1863680573): 0: core::panicking::panic_nounwind_fmt (called) 1: >::get_unchecked_mut::precondition_check (called) 2: >::get_unchecked_mut (called)