From 467d614267ce422206d8acbccf957eb49a597467 Mon Sep 17 00:00:00 2001 From: Charlie Tonneslan Date: Sun, 22 Mar 2026 09:00:12 -0400 Subject: [PATCH] bench: use is_multiple_of instead of manual modulo check (#7984) Addresses clippy::manual_is_multiple_of warning on latest stable. --- benches/remote_spawn.rs | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/benches/remote_spawn.rs b/benches/remote_spawn.rs index 73032aa7b..f9fbbe51a 100644 --- a/benches/remote_spawn.rs +++ b/benches/remote_spawn.rs @@ -19,7 +19,10 @@ use tokio::runtime::{self, Runtime}; /// Total number of tasks spawned across all threads per iteration. /// Must be divisible by the largest parallelism level (64). const TOTAL_TASKS: usize = 12_800; -const _: () = assert!(TOTAL_TASKS % 64 == 0, "TOTAL_TASKS must be divisible by 64"); +const _: () = assert!( + TOTAL_TASKS.is_multiple_of(64), + "TOTAL_TASKS must be divisible by 64" +); fn remote_spawn_contention(c: &mut Criterion) { let parallelism_levels = parallelism_levels();