From 2a6826d25d2d7721068429807d19d13f828d338c Mon Sep 17 00:00:00 2001 From: Dan Gohman Date: Fri, 31 Jan 2025 09:00:00 -0800 Subject: [PATCH] powerp64 defines a stat64 but doesn't use it. --- src/backend/linux_raw/fs/types.rs | 2 +- src/fs/constants.rs | 34 +++++++++++++------------------ 2 files changed, 15 insertions(+), 21 deletions(-) diff --git a/src/backend/linux_raw/fs/types.rs b/src/backend/linux_raw/fs/types.rs index cb546fb8d..62abb8e6f 100644 --- a/src/backend/linux_raw/fs/types.rs +++ b/src/backend/linux_raw/fs/types.rs @@ -697,7 +697,7 @@ pub struct Stat { pub(crate) __unused4: ffi::c_uint, pub(crate) __unused5: ffi::c_uint, } -// This follows `stat64`. +// This follows `stat`. powerpc64 defines a `stat64` but it's not used. #[repr(C)] #[derive(Debug, Copy, Clone)] #[allow(missing_docs)] diff --git a/src/fs/constants.rs b/src/fs/constants.rs index f4826ba98..6496db79b 100644 --- a/src/fs/constants.rs +++ b/src/fs/constants.rs @@ -69,16 +69,13 @@ mod tests { )))] { // Check that `Stat` matches `c::stat`. - #[cfg(not(any( - all(linux_raw, target_arch = "powerpc64"), - all( - libc, - any( - all(linux_kernel, target_pointer_width = "64"), - target_os = "hurd", - target_os = "emscripten", - target_os = "l4re", - ) + #[cfg(not(all( + libc, + any( + all(linux_kernel, target_pointer_width = "64"), + target_os = "hurd", + target_os = "emscripten", + target_os = "l4re", ) )))] { @@ -155,16 +152,13 @@ mod tests { } // Check that `Stat` matches `c::stat64`. - #[cfg(any( - all(linux_raw, target_arch = "powerpc64"), - all( - libc, - any( - all(linux_kernel, target_pointer_width = "64"), - target_os = "hurd", - target_os = "emscripten", - target_os = "l4re", - ) + #[cfg(all( + libc, + any( + all(linux_kernel, target_pointer_width = "64"), + target_os = "hurd", + target_os = "emscripten", + target_os = "l4re", ) ))] {