Use static inline in Visual C++.

static inline can be used in Visual C++ 2015, but even for older versions we can use static __inline instead of just static.
This commit is contained in:
Wedge009 2015-08-15 11:15:43 +10:00
parent 929ec99d6f
commit 0bc874626f

View file

@ -244,7 +244,7 @@ typedef struct GPU_MatrixStack
typedef struct GPU_Context
{
/*! SDL_GLContext */
void* context;
void* context;
Uint8 failed;
/*! SDL window ID */
@ -800,9 +800,9 @@ struct GPU_Renderer
// Setup calls
// Visual C does not support static inline
#ifdef _MSC_VER
static SDL_version GPU_GetCompiledVersion(void)
// static inline only supported in Visual C++ from version 2015 but can use static __inline instead for older versions
#if _MSC_VER < 1900
static __inline SDL_version GPU_GetCompiledVersion(void)
#else
static inline SDL_version GPU_GetCompiledVersion(void)
#endif