Skip to content

Commit 87cbd8c

Browse files
authored
Rollup merge of rust-lang#98516 - dlrobertson:uefi_va_list, r=joshtriplett
library: fix uefi va_list type definition For uefi the `va_list` should always be the void pointer variant. Related to: rust-lang#44930
2 parents 9c271bb + 7a72c0a commit 87cbd8c

File tree

1 file changed

+16
-9
lines changed

1 file changed

+16
-9
lines changed

core/src/ffi/mod.rs

+16-9
Original file line numberDiff line numberDiff line change
@@ -231,7 +231,8 @@ impl fmt::Debug for c_void {
231231
all(target_arch = "aarch64", any(target_os = "macos", target_os = "ios")),
232232
target_family = "wasm",
233233
target_arch = "asmjs",
234-
windows
234+
target_os = "uefi",
235+
windows,
235236
))]
236237
#[repr(transparent)]
237238
#[unstable(
@@ -254,7 +255,8 @@ pub struct VaListImpl<'f> {
254255
all(target_arch = "aarch64", any(target_os = "macos", target_os = "ios")),
255256
target_family = "wasm",
256257
target_arch = "asmjs",
257-
windows
258+
target_os = "uefi",
259+
windows,
258260
))]
259261
#[unstable(
260262
feature = "c_variadic",
@@ -276,7 +278,8 @@ impl<'f> fmt::Debug for VaListImpl<'f> {
276278
#[cfg(all(
277279
target_arch = "aarch64",
278280
not(any(target_os = "macos", target_os = "ios")),
279-
not(windows)
281+
not(target_os = "uefi"),
282+
not(windows),
280283
))]
281284
#[repr(C)]
282285
#[derive(Debug)]
@@ -297,7 +300,7 @@ pub struct VaListImpl<'f> {
297300
}
298301

299302
/// PowerPC ABI implementation of a `va_list`.
300-
#[cfg(all(target_arch = "powerpc", not(windows)))]
303+
#[cfg(all(target_arch = "powerpc", not(target_os = "uefi"), not(windows)))]
301304
#[repr(C)]
302305
#[derive(Debug)]
303306
#[unstable(
@@ -317,7 +320,7 @@ pub struct VaListImpl<'f> {
317320
}
318321

319322
/// x86_64 ABI implementation of a `va_list`.
320-
#[cfg(all(target_arch = "x86_64", not(windows)))]
323+
#[cfg(all(target_arch = "x86_64", not(target_os = "uefi"), not(windows)))]
321324
#[repr(C)]
322325
#[derive(Debug)]
323326
#[unstable(
@@ -354,7 +357,8 @@ pub struct VaList<'a, 'f: 'a> {
354357
all(target_arch = "aarch64", any(target_os = "macos", target_os = "ios")),
355358
target_family = "wasm",
356359
target_arch = "asmjs",
357-
windows
360+
target_os = "uefi",
361+
windows,
358362
))]
359363
inner: VaListImpl<'f>,
360364

@@ -363,7 +367,8 @@ pub struct VaList<'a, 'f: 'a> {
363367
any(not(target_arch = "aarch64"), not(any(target_os = "macos", target_os = "ios"))),
364368
not(target_family = "wasm"),
365369
not(target_arch = "asmjs"),
366-
not(windows)
370+
not(target_os = "uefi"),
371+
not(windows),
367372
))]
368373
inner: &'a mut VaListImpl<'f>,
369374

@@ -375,7 +380,8 @@ pub struct VaList<'a, 'f: 'a> {
375380
all(target_arch = "aarch64", any(target_os = "macos", target_os = "ios")),
376381
target_family = "wasm",
377382
target_arch = "asmjs",
378-
windows
383+
target_os = "uefi",
384+
windows,
379385
))]
380386
#[unstable(
381387
feature = "c_variadic",
@@ -396,7 +402,8 @@ impl<'f> VaListImpl<'f> {
396402
any(not(target_arch = "aarch64"), not(any(target_os = "macos", target_os = "ios"))),
397403
not(target_family = "wasm"),
398404
not(target_arch = "asmjs"),
399-
not(windows)
405+
not(target_os = "uefi"),
406+
not(windows),
400407
))]
401408
#[unstable(
402409
feature = "c_variadic",

0 commit comments

Comments
 (0)