mirror of
https://github.com/python/cpython.git
synced 2025-09-26 18:29:57 +00:00
gh-90815: Fix mimalloc atomic.h on Windows arm64 (#111527)
mi_atomic_load_explicit() casts 'p' argument to drop the 'const' qualifier on Windows arm64 platform. Fix the compiler warning: 'function': different 'const' qualifiers (compiling source file ..\Objects\mimalloc\options.c)
This commit is contained in:
parent
1673e44017
commit
801741ff81
1 changed files with 1 additions and 1 deletions
|
@ -195,7 +195,7 @@ static inline uintptr_t mi_atomic_load_explicit(_Atomic(uintptr_t) const* p, mi_
|
||||||
#else
|
#else
|
||||||
uintptr_t x = *p;
|
uintptr_t x = *p;
|
||||||
if (mo > mi_memory_order_relaxed) {
|
if (mo > mi_memory_order_relaxed) {
|
||||||
while (!mi_atomic_compare_exchange_weak_explicit(p, &x, x, mo, mi_memory_order_relaxed)) { /* nothing */ };
|
while (!mi_atomic_compare_exchange_weak_explicit((_Atomic(uintptr_t)*)p, &x, x, mo, mi_memory_order_relaxed)) { /* nothing */ };
|
||||||
}
|
}
|
||||||
return x;
|
return x;
|
||||||
#endif
|
#endif
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue