From dc967257254fa50501526a87403b22acecf691d1 Mon Sep 17 00:00:00 2001 From: Brandon Thomas Date: Tue, 6 Oct 2026 08:46:22 -0400 Subject: [PATCH] audio: allow the deprecated fetch_update while rust-version is 1.95 Rust 1.99 renamed AtomicU32::fetch_update to try_update; try_update is not available on the workspace's minimum Rust (1.95). Co-Authored-By: Claude Opus 5.5 --- crates/ui-egui/src/audio.rs | 3 +++ 1 file changed, 3 insertions(+) diff --git a/crates/ui-egui/src/audio.rs b/crates/ui-egui/src/audio.rs index 1456f601..dbc37b5d 100644 --- a/crates/ui-egui/src/audio.rs +++ b/crates/ui-egui/src/audio.rs @@ -92,6 +92,9 @@ impl AudioFeed { out[real..].iter_mut().for_each(|o| *o = 0.0); self.consumed.fetch_add((real / 2) as u64, Ordering::Relaxed); for (c, v) in pk.into_iter().enumerate() { + // Rust 1.99 renamed `fetch_update` to `try_update`; keep the old name while the + // workspace supports Rust 1.95 (`rust-version`). + #[allow(deprecated)] let _ = self.peak[c].fetch_update(Ordering::Relaxed, Ordering::Relaxed, |old| (v > f32::from_bits(old)).then_some(v.to_bits())); } }