CNIOAtomics: define types for `uintptr_t` and `intptr_t` (#1401)

On LLP64 hosts, `Int` is mapped to `intptr_t` and `UInt` to `uintptr_t`.
As a result, we need to ensure that we map the atomic extensions to
those types for type conversions.

Add the types for `uintptr_t` and `intptr_t` so that they can be used to
implement `CNIOConcurrencyHelpers` on Windows.

Co-authored-by: Johannes Weiss <johannesweiss@apple.com>
This commit is contained in:
Saleem Abdulrasool 2020-02-26 09:07:39 -08:00 committed by GitHub
parent 8ad2549a49
commit 1595c42b9a
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 7 additions and 2 deletions

View File

@ -70,4 +70,7 @@ DECLARE_ATOMIC_OPERATIONS(uint_least32_t, uint_least32_t)
DECLARE_ATOMIC_OPERATIONS(int_least64_t, int_least64_t)
DECLARE_ATOMIC_OPERATIONS(uint_least64_t, uint_least64_t)
DECLARE_ATOMIC_OPERATIONS(intptr_t, intptr_t)
DECLARE_ATOMIC_OPERATIONS(uintptr_t, uintptr_t)
#undef DECLARE_ATOMIC_OPERATIONS

View File

@ -81,5 +81,6 @@ MAP(MAKE,EMPTY,
int_least8_t, uint_least8_t,
int_least16_t, uint_least16_t,
int_least32_t, uint_least32_t,
int_least64_t, uint_least64_t
int_least64_t, uint_least64_t,
intptr_t, uintptr_t
)

View File

@ -71,5 +71,6 @@ MAP(MAKE,EMPTY,
int_least8_t, uint_least8_t,
int_least16_t, uint_least16_t,
int_least32_t, uint_least32_t,
int_least64_t, uint_least64_t
int_least64_t, uint_least64_t,
intptr_t, uintptr_t
)