Skip to content

Commit a854e8e

Browse files
authored
Merge pull request #40075 from compnerd/safes-should-be-strong
Shims: strongly link `swift_isStackAllocationSafe` on !Darwin
2 parents ad0a5bf + d001831 commit a854e8e

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

stdlib/public/SwiftShims/RuntimeShims.h

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -93,7 +93,10 @@ __swift_size_t _swift_stdlib_getHardwareConcurrency(void);
9393
///
9494
/// This function is used by
9595
/// @c withUnsafeTemporaryAllocation(byteCount:alignment:_:).
96-
SWIFT_RUNTIME_STDLIB_API SWIFT_WEAK_IMPORT
96+
SWIFT_RUNTIME_STDLIB_API
97+
#if defined(__APPLE__) && defined(__MACH__)
98+
SWIFT_WEAK_IMPORT
99+
#endif
97100
__swift_bool swift_stdlib_isStackAllocationSafe(__swift_size_t byteCount,
98101
__swift_size_t alignment);
99102

0 commit comments

Comments
 (0)