@@ -27,11 +27,11 @@ #endif OF_ASSUME_NONNULL_BEGIN static OF_INLINE int -of_atomic_int_add(volatile int *OF_NONNULL p, int i) +of_atomic_int_add(volatile int *_Nonnull p, int i) { #if !defined(OF_HAVE_THREADS) return (*p += i); #elif defined(OF_HAVE_GCC_ATOMIC_OPS) return __sync_add_and_fetch(p, i); @@ -76,11 +76,11 @@ # error of_atomic_int_add not implemented! #endif } static OF_INLINE int32_t -of_atomic_int32_add(volatile int32_t *OF_NONNULL p, int32_t i) +of_atomic_int32_add(volatile int32_t *_Nonnull p, int32_t i) { #if !defined(OF_HAVE_THREADS) return (*p += i); #elif defined(OF_HAVE_GCC_ATOMIC_OPS) return __sync_add_and_fetch(p, i); @@ -112,11 +112,11 @@ # error of_atomic_int32_add not implemented! #endif } static OF_INLINE void* -of_atomic_ptr_add(void *volatile OF_NULLABLE *OF_NONNULL p, intptr_t i) +of_atomic_ptr_add(void *volatile _Nullable *_Nonnull p, intptr_t i) { #if !defined(OF_HAVE_THREADS) return (*(char* volatile*)p += i); #elif defined(OF_HAVE_GCC_ATOMIC_OPS) return __sync_add_and_fetch(p, (void*)i); @@ -162,11 +162,11 @@ # error of_atomic_ptr_add not implemented! #endif } static OF_INLINE int -of_atomic_int_sub(volatile int *OF_NONNULL p, int i) +of_atomic_int_sub(volatile int *_Nonnull p, int i) { #if !defined(OF_HAVE_THREADS) return (*p -= i); #elif defined(OF_HAVE_GCC_ATOMIC_OPS) return __sync_sub_and_fetch(p, i); @@ -213,11 +213,11 @@ # error of_atomic_int_sub not implemented! #endif } static OF_INLINE int32_t -of_atomic_int32_sub(volatile int32_t *OF_NONNULL p, int32_t i) +of_atomic_int32_sub(volatile int32_t *_Nonnull p, int32_t i) { #if !defined(OF_HAVE_THREADS) return (*p -= i); #elif defined(OF_HAVE_GCC_ATOMIC_OPS) return __sync_sub_and_fetch(p, i); @@ -250,11 +250,11 @@ # error of_atomic_int32_sub not implemented! #endif } static OF_INLINE void* -of_atomic_ptr_sub(void *volatile OF_NULLABLE *OF_NONNULL p, intptr_t i) +of_atomic_ptr_sub(void *volatile _Nullable *_Nonnull p, intptr_t i) { #if !defined(OF_HAVE_THREADS) return (*(char* volatile*)p -= i); #elif defined(OF_HAVE_GCC_ATOMIC_OPS) return __sync_sub_and_fetch(p, (void*)i); @@ -302,11 +302,11 @@ # error of_atomic_ptr_sub not implemented! #endif } static OF_INLINE int -of_atomic_int_inc(volatile int *OF_NONNULL p) +of_atomic_int_inc(volatile int *_Nonnull p) { #if !defined(OF_HAVE_THREADS) return ++*p; #elif defined(OF_HAVE_GCC_ATOMIC_OPS) return __sync_add_and_fetch(p, 1); @@ -359,11 +359,11 @@ # error of_atomic_int_inc not implemented! #endif } static OF_INLINE int32_t -of_atomic_int32_inc(volatile int32_t *OF_NONNULL p) +of_atomic_int32_inc(volatile int32_t *_Nonnull p) { #if !defined(OF_HAVE_THREADS) return ++*p; #elif defined(OF_HAVE_GCC_ATOMIC_OPS) return __sync_add_and_fetch(p, 1); @@ -401,11 +401,11 @@ # error of_atomic_int32_inc not implemented! #endif } static OF_INLINE int -of_atomic_int_dec(volatile int *OF_NONNULL p) +of_atomic_int_dec(volatile int *_Nonnull p) { #if !defined(OF_HAVE_THREADS) return --*p; #elif defined(OF_HAVE_GCC_ATOMIC_OPS) return __sync_sub_and_fetch(p, 1); @@ -458,11 +458,11 @@ # error of_atomic_int_dec not implemented! #endif } static OF_INLINE int32_t -of_atomic_int32_dec(volatile int32_t *OF_NONNULL p) +of_atomic_int32_dec(volatile int32_t *_Nonnull p) { #if !defined(OF_HAVE_THREADS) return --*p; #elif defined(OF_HAVE_GCC_ATOMIC_OPS) return __sync_sub_and_fetch(p, 1); @@ -500,11 +500,11 @@ # error of_atomic_int32_dec not implemented! #endif } static OF_INLINE unsigned int -of_atomic_int_or(volatile unsigned int *OF_NONNULL p, unsigned int i) +of_atomic_int_or(volatile unsigned int *_Nonnull p, unsigned int i) { #if !defined(OF_HAVE_THREADS) return (*p |= i); #elif defined(OF_HAVE_GCC_ATOMIC_OPS) return __sync_or_and_fetch(p, i); @@ -559,11 +559,11 @@ # error of_atomic_int_or not implemented! #endif } static OF_INLINE uint32_t -of_atomic_int32_or(volatile uint32_t *OF_NONNULL p, uint32_t i) +of_atomic_int32_or(volatile uint32_t *_Nonnull p, uint32_t i) { #if !defined(OF_HAVE_THREADS) return (*p |= i); #elif defined(OF_HAVE_GCC_ATOMIC_OPS) return __sync_or_and_fetch(p, i); @@ -600,11 +600,11 @@ # error of_atomic_int32_or not implemented! #endif } static OF_INLINE unsigned int -of_atomic_int_and(volatile unsigned int *OF_NONNULL p, unsigned int i) +of_atomic_int_and(volatile unsigned int *_Nonnull p, unsigned int i) { #if !defined(OF_HAVE_THREADS) return (*p &= i); #elif defined(OF_HAVE_GCC_ATOMIC_OPS) return __sync_and_and_fetch(p, i); @@ -659,11 +659,11 @@ # error of_atomic_int_and not implemented! #endif } static OF_INLINE uint32_t -of_atomic_int32_and(volatile uint32_t *OF_NONNULL p, uint32_t i) +of_atomic_int32_and(volatile uint32_t *_Nonnull p, uint32_t i) { #if !defined(OF_HAVE_THREADS) return (*p &= i); #elif defined(OF_HAVE_GCC_ATOMIC_OPS) return __sync_and_and_fetch(p, i); @@ -700,11 +700,11 @@ # error of_atomic_int32_and not implemented! #endif } static OF_INLINE unsigned int -of_atomic_int_xor(volatile unsigned int *OF_NONNULL p, unsigned int i) +of_atomic_int_xor(volatile unsigned int *_Nonnull p, unsigned int i) { #if !defined(OF_HAVE_THREADS) return (*p ^= i); #elif defined(OF_HAVE_GCC_ATOMIC_OPS) return __sync_xor_and_fetch(p, i); @@ -759,11 +759,11 @@ # error of_atomic_int_xor not implemented! #endif } static OF_INLINE uint32_t -of_atomic_int32_xor(volatile uint32_t *OF_NONNULL p, uint32_t i) +of_atomic_int32_xor(volatile uint32_t *_Nonnull p, uint32_t i) { #if !defined(OF_HAVE_THREADS) return (*p ^= i); #elif defined(OF_HAVE_GCC_ATOMIC_OPS) return __sync_xor_and_fetch(p, i); @@ -800,11 +800,11 @@ # error of_atomic_int32_xor not implemented! #endif } static OF_INLINE bool -of_atomic_int_cmpswap(volatile int *OF_NONNULL p, int o, int n) +of_atomic_int_cmpswap(volatile int *_Nonnull p, int o, int n) { #if !defined(OF_HAVE_THREADS) if (*p == o) { *p = n; return true; @@ -855,11 +855,11 @@ # error of_atomic_int_cmpswap not implemented! #endif } static OF_INLINE bool -of_atomic_int32_cmpswap(volatile int32_t *OF_NONNULL p, int32_t o, int32_t n) +of_atomic_int32_cmpswap(volatile int32_t *_Nonnull p, int32_t o, int32_t n) { #if !defined(OF_HAVE_THREADS) if (*p == o) { *p = n; return true; @@ -910,12 +910,12 @@ # error of_atomic_int32_cmpswap not implemented! #endif } static OF_INLINE bool -of_atomic_ptr_cmpswap(void *volatile OF_NULLABLE *OF_NONNULL p, - void *OF_NULLABLE o, void *OF_NULLABLE n) +of_atomic_ptr_cmpswap(void *volatile _Nullable *_Nonnull p, + void *_Nullable o, void *_Nullable n) { #if !defined(OF_HAVE_THREADS) if (*p == o) { *p = n; return true;