This is an automated email from the ASF dual-hosted git repository.

hubcio pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/iggy.git


The following commit(s) were added to refs/heads/master by this push:
     new dc54783f2 fix(server): resolve non-Linux clippy errors in shard 
binding (#4144)
dc54783f2 is described below

commit dc54783f2833347bb2e6696817d81019956ee00f
Author: Alan Tang <[email protected]>
AuthorDate: Sat Sep 12 21:37:54 2026 +0800

    fix(server): resolve non-Linux clippy errors in shard binding (#4144)
---
 core/server/src/shard_allocator.rs | 16 ++++++++++++++++
 1 file changed, 16 insertions(+)

diff --git a/core/server/src/shard_allocator.rs 
b/core/server/src/shard_allocator.rs
index e71ddbfac..98befb1e6 100644
--- a/core/server/src/shard_allocator.rs
+++ b/core/server/src/shard_allocator.rs
@@ -210,6 +210,14 @@ pub struct ShardInfo {
 impl ShardInfo {
     /// Pin the calling thread to this shard's cores. On non-Linux this
     /// does nothing (no-op). Empty core set also does nothing.
+    #[cfg_attr(
+        not(target_os = "linux"),
+        allow(
+            clippy::unused_self,
+            clippy::unnecessary_wraps,
+            reason = "Keep the same API as the fallible Linux binding 
implementation"
+        )
+    )]
     pub fn bind_cpu(&self) -> Result<(), ShardingError> {
         #[cfg(target_os = "linux")]
         {
@@ -241,6 +249,14 @@ impl ShardInfo {
     /// Pin the calling thread's memory to this shard's NUMA node so
     /// allocations stay local and fast. Does nothing if no node is set.
     /// On non-Linux this does nothing (no-op), mirroring [`Self::bind_cpu`].
+    #[cfg_attr(
+        not(target_os = "linux"),
+        allow(
+            clippy::unused_self,
+            clippy::unnecessary_wraps,
+            reason = "Keep the same API as the fallible Linux binding 
implementation"
+        )
+    )]
     pub fn bind_memory(&self) -> Result<(), ShardingError> {
         #[cfg(target_os = "linux")]
         {

Reply via email to