Skip to content

Commit 8e6d86e

Browse files
committed
shims: correct __swift_mode_t for android-aarch64
android on AArch64 will alias `mode_t` to `__kernel_mode_t` which is aliased to `unsigned int` rather than `unsigned short` like it is on the other targets. Update the condition to reflect that.
1 parent 814e656 commit 8e6d86e

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

stdlib/public/SwiftShims/LibcShims.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,7 @@ typedef long int __swift_ssize_t;
5050
// This declaration might not be universally correct.
5151
// We verify its correctness for the current platform in the runtime code.
5252
#if defined(__linux__)
53-
# if defined(__ANDROID__)
53+
# if defined(__ANDROID__) && !defined(__aarch64__)
5454
typedef __swift_uint16_t __swift_mode_t;
5555
# else
5656
typedef __swift_uint32_t __swift_mode_t;

0 commit comments

Comments
 (0)