Fixed compiler warnings with SDL_FORCE_INLINE on gcc2. (Thanks, Axel!)
authorRyan C. Gordon <icculus@icculus.org>
Fri, 29 Mar 2013 21:13:16 -0400
changeset 7032 305feca4f152
parent 7031 3242aa26100f
child 7033 3b12bae22f9e
Fixed compiler warnings with SDL_FORCE_INLINE on gcc2. (Thanks, Axel!) Fixes Bugzilla #1770.
include/begin_code.h
--- a/include/begin_code.h	Tue Mar 26 22:26:07 2013 -0700
+++ b/include/begin_code.h	Fri Mar 29 21:13:16 2013 -0400
@@ -130,7 +130,7 @@
 
 #if defined(_MSC_VER)
 #define SDL_FORCE_INLINE __forceinline
-#elif defined(__GNUC__) || defined(__clang__)
+#elif ( (defined(__GNUC__) && (__GNUC__ >= 4)) || defined(__clang__) )
 #define SDL_FORCE_INLINE __attribute__((always_inline)) static inline
 #else
 #define SDL_FORCE_INLINE static __inline__