Commit 06aed127 authored by Sam Lantinga's avatar Sam Lantinga

Not all MinGW compilers have intrin.h, so we'll only use this with Visual Studio.

That's actually okay, since gcc has the builtin atomic intrinsics. :)
parent c4fe663b
...@@ -112,7 +112,7 @@ extern DECLSPEC void SDLCALL SDL_AtomicUnlock(SDL_SpinLock *lock); ...@@ -112,7 +112,7 @@ extern DECLSPEC void SDLCALL SDL_AtomicUnlock(SDL_SpinLock *lock);
*/ */
#ifndef SDL_DISABLE_ATOMIC_INLINE #ifndef SDL_DISABLE_ATOMIC_INLINE
#if defined(__WIN32__) #if defined(_MSC_VER)
#include <intrin.h> #include <intrin.h>
#define SDL_AtomicSet(a, v) _InterlockedExchange((long*)&(a)->value, (v)) #define SDL_AtomicSet(a, v) _InterlockedExchange((long*)&(a)->value, (v))
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment