comparison include/SDL_endian.h @ 1372:3e171fa5f4df

Whoops
author Sam Lantinga <slouken@libsdl.org>
date Sun, 19 Feb 2006 06:02:57 +0000
parents 42eeb14770e3
children 4ed717f9e509
comparison
equal deleted inserted replaced
1371:e2641c13bf33 1372:3e171fa5f4df
55 /* Use inline functions for compilers that support them, and static 55 /* Use inline functions for compilers that support them, and static
56 functions for those that do not. Because these functions become 56 functions for those that do not. Because these functions become
57 static for compilers that do not support inline functions, this 57 static for compilers that do not support inline functions, this
58 header should only be included in files that actually use them. 58 header should only be included in files that actually use them.
59 */ 59 */
60 #if defined(__GNUC__) && defined(__i386__) && 60 #if defined(__GNUC__) && defined(__i386__) && \
61 !(__GNUC__ == 2 && __GNUC_MINOR__ == 95 /* broken gcc version */) 61 !(__GNUC__ == 2 && __GNUC_MINOR__ == 95 /* broken gcc version */)
62 static __inline__ Uint16 SDL_Swap16(Uint16 x) 62 static __inline__ Uint16 SDL_Swap16(Uint16 x)
63 { 63 {
64 __asm__("xchgb %b0,%h0" : "=q" (x) : "0" (x)); 64 __asm__("xchgb %b0,%h0" : "=q" (x) : "0" (x));
65 return x; 65 return x;