minor cleanup for watcom _inline keyword.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109
diff --git a/include/SDL_atomic.h b/include/SDL_atomic.h
index db0dbe9..1ca0ad0 100644
--- a/include/SDL_atomic.h
+++ b/include/SDL_atomic.h
@@ -152,7 +152,7 @@ void _ReadWriteBarrier(void);
/* This is correct for all CPUs when using GCC or Solaris Studio 12.1+. */
#define SDL_CompilerBarrier() __asm__ __volatile__ ("" : : : "memory")
#elif defined(__WATCOMC__)
-extern _inline void SDL_CompilerBarrier (void);
+extern __inline void SDL_CompilerBarrier(void);
#pragma aux SDL_CompilerBarrier = "" parm [] modify exact [];
#else
#define SDL_CompilerBarrier() \
diff --git a/include/SDL_bits.h b/include/SDL_bits.h
index 553b687..1a7e95c 100644
--- a/include/SDL_bits.h
+++ b/include/SDL_bits.h
@@ -48,7 +48,7 @@ extern "C" {
* \return the index of the most significant bit, or -1 if the value is 0.
*/
#if defined(__WATCOMC__) && defined(__386__)
-extern _inline int _SDL_bsr_watcom (Uint32);
+extern __inline int _SDL_bsr_watcom(Uint32);
#pragma aux _SDL_bsr_watcom = \
"bsr eax, eax" \
parm [eax] nomemory \
diff --git a/include/SDL_endian.h b/include/SDL_endian.h
index 3306003..ac6af39 100644
--- a/include/SDL_endian.h
+++ b/include/SDL_endian.h
@@ -150,7 +150,7 @@ SDL_Swap16(Uint16 x)
return x;
}
#elif defined(__WATCOMC__) && defined(__386__)
-extern _inline Uint16 SDL_Swap16(Uint16);
+extern __inline Uint16 SDL_Swap16(Uint16);
#pragma aux SDL_Swap16 = \
"xchg al, ah" \
parm [ax] \
@@ -208,7 +208,7 @@ SDL_Swap32(Uint32 x)
return x;
}
#elif defined(__WATCOMC__) && defined(__386__)
-extern _inline Uint32 SDL_Swap32(Uint32);
+extern __inline Uint32 SDL_Swap32(Uint32);
#pragma aux SDL_Swap32 = \
"bswap eax" \
parm [eax] \
@@ -251,7 +251,7 @@ SDL_Swap64(Uint64 x)
return x;
}
#elif defined(__WATCOMC__) && defined(__386__)
-extern _inline Uint64 SDL_Swap64(Uint64);
+extern __inline Uint64 SDL_Swap64(Uint64);
#pragma aux SDL_Swap64 = \
"bswap eax" \
"bswap edx" \
diff --git a/src/atomic/SDL_atomic.c b/src/atomic/SDL_atomic.c
index 58f891b..5973aa8 100644
--- a/src/atomic/SDL_atomic.c
+++ b/src/atomic/SDL_atomic.c
@@ -53,14 +53,14 @@
#if defined(__WATCOMC__) && defined(__386__)
SDL_COMPILE_TIME_ASSERT(intsize, 4==sizeof(int));
#define HAVE_WATCOM_ATOMICS
-extern _inline int _SDL_xchg_watcom(volatile int *a, int v);
+extern __inline int _SDL_xchg_watcom(volatile int *a, int v);
#pragma aux _SDL_xchg_watcom = \
"lock xchg [ecx], eax" \
parm [ecx] [eax] \
value [eax] \
modify exact [eax];
-extern _inline unsigned char _SDL_cmpxchg_watcom(volatile int *a, int newval, int oldval);
+extern __inline unsigned char _SDL_cmpxchg_watcom(volatile int *a, int newval, int oldval);
#pragma aux _SDL_cmpxchg_watcom = \
"lock cmpxchg [edx], ecx" \
"setz al" \
@@ -68,7 +68,7 @@ extern _inline unsigned char _SDL_cmpxchg_watcom(volatile int *a, int newval, in
value [al] \
modify exact [eax];
-extern _inline int _SDL_xadd_watcom(volatile int *a, int v);
+extern __inline int _SDL_xadd_watcom(volatile int *a, int v);
#pragma aux _SDL_xadd_watcom = \
"lock xadd [ecx], eax" \
parm [ecx] [eax] \
diff --git a/src/atomic/SDL_spinlock.c b/src/atomic/SDL_spinlock.c
index 63b8bd9..89378b1 100644
--- a/src/atomic/SDL_spinlock.c
+++ b/src/atomic/SDL_spinlock.c
@@ -42,7 +42,7 @@
#if defined(__WATCOMC__) && defined(__386__)
SDL_COMPILE_TIME_ASSERT(locksize, 4==sizeof(SDL_SpinLock));
-extern _inline int _SDL_xchg_watcom(volatile int *a, int v);
+extern __inline int _SDL_xchg_watcom(volatile int *a, int v);
#pragma aux _SDL_xchg_watcom = \
"lock xchg [ecx], eax" \
parm [ecx] [eax] \
@@ -151,7 +151,7 @@ SDL_AtomicTryLock(SDL_SpinLock *lock)
#define PAUSE_INSTRUCTION() __yield()
#elif defined(__WATCOMC__) && defined(__386__)
/* watcom assembler rejects PAUSE if CPU < i686, and it refuses REP NOP as an invalid combination. Hardcode the bytes. */
- extern _inline void PAUSE_INSTRUCTION(void);
+ extern __inline void PAUSE_INSTRUCTION(void);
#pragma aux PAUSE_INSTRUCTION = "db 0f3h,90h"
#else
#define PAUSE_INSTRUCTION()