[atomic] Change Windows atomic int type to int

This commit is contained in:
Behdad Esfahbod 2018-08-08 22:42:33 -07:00
parent aee2d10b2b
commit e1de86eac1
1 changed files with 2 additions and 2 deletions

View File

@ -101,8 +101,8 @@ static inline void _hb_memory_barrier (void)
}
#define _hb_memory_barrier() _hb_memory_barrier ()
typedef LONG hb_atomic_int_impl_t;
#define hb_atomic_int_impl_add(AI, V) InterlockedExchangeAdd ((AI), (V))
typedef int hb_atomic_int_impl_t;
#define hb_atomic_int_impl_add(AI, V) InterlockedExchangeAdd ((unsigned *) (AI), (V))
#define hb_atomic_ptr_impl_cmpexch(P,O,N) (InterlockedCompareExchangePointer ((void **) (P), (void *) (N), (void *) (O)) == (void *) (O))