From cdd6e9cde27519657165552243df66a21dc73bd8 Mon Sep 17 00:00:00 2001 From: Sergey Fedorov Date: Thu, 18 Dec 2025 00:24:24 +0800 Subject: [PATCH 7/7] ffi.rs: adjust powerpc for macOS --- library/core/src/ffi.rs | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/library/core/src/ffi.rs b/library/core/src/ffi.rs index b208ddd4b27..58196fd6c15 100644 --- a/library/core/src/ffi.rs +++ b/library/core/src/ffi.rs @@ -62,6 +62,7 @@ fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result { #[cfg(any( all(not(target_arch = "aarch64"), not(target_arch = "powerpc"), not(target_arch = "x86_64")), all(target_arch = "aarch64", any(target_os = "macos", target_os = "ios")), + all(target_arch = "powerpc", target_os = "macos"), target_arch = "wasm32", target_arch = "asmjs", windows @@ -85,6 +86,7 @@ pub struct VaListImpl<'f> { #[cfg(any( all(not(target_arch = "aarch64"), not(target_arch = "powerpc"), not(target_arch = "x86_64")), all(target_arch = "aarch64", any(target_os = "macos", target_os = "ios")), + all(target_arch = "powerpc", target_os = "macos"), target_arch = "wasm32", target_arch = "asmjs", windows @@ -130,7 +132,7 @@ pub struct VaListImpl<'f> { } /// PowerPC ABI implementation of a `va_list`. -#[cfg(all(target_arch = "powerpc", not(windows)))] +#[cfg(all(target_arch = "powerpc", not(any(target_os = "macos", windows))))] #[repr(C)] #[derive(Debug)] #[unstable( @@ -185,6 +187,7 @@ pub struct VaList<'a, 'f: 'a> { not(target_arch = "x86_64") ), all(target_arch = "aarch64", any(target_os = "macos", target_os = "ios")), + all(target_arch = "powerpc", target_os = "macos"), target_arch = "wasm32", target_arch = "asmjs", windows @@ -194,6 +197,7 @@ pub struct VaList<'a, 'f: 'a> { #[cfg(all( any(target_arch = "aarch64", target_arch = "powerpc", target_arch = "x86_64"), any(not(target_arch = "aarch64"), not(any(target_os = "macos", target_os = "ios"))), + any(not(target_arch = "powerpc"), not(target_os = "macos")), not(target_arch = "wasm32"), not(target_arch = "asmjs"), not(windows) @@ -206,6 +210,7 @@ pub struct VaList<'a, 'f: 'a> { #[cfg(any( all(not(target_arch = "aarch64"), not(target_arch = "powerpc"), not(target_arch = "x86_64")), all(target_arch = "aarch64", any(target_os = "macos", target_os = "ios")), + all(target_arch = "powerpc", target_os = "macos"), target_arch = "wasm32", target_arch = "asmjs", windows @@ -227,6 +232,7 @@ pub fn as_va_list<'a>(&'a mut self) -> VaList<'a, 'f> { #[cfg(all( any(target_arch = "aarch64", target_arch = "powerpc", target_arch = "x86_64"), any(not(target_arch = "aarch64"), not(any(target_os = "macos", target_os = "ios"))), + any(not(target_arch = "powerpc"), not(target_os = "macos")), not(target_arch = "wasm32"), not(target_arch = "asmjs"), not(windows) -- 2.52.0