Check for _MSC_VER definition first

Forgot the need to check for the presence of _MSC_VER definition before it can be compared against the value for VC 2015.
This commit is contained in:
Wedge009 2015-08-17 00:11:16 +10:00
parent c4c2eaa257
commit a88e777e05

View File

@ -801,11 +801,15 @@ struct GPU_Renderer
// Setup calls // Setup calls
// static inline only supported in Visual C++ from version 2015 but can use static __inline instead for older versions // static inline only supported in Visual C++ from version 2015 but can use static __inline instead for older versions
#ifdef _MSC_VER
#if _MSC_VER < 1900 #if _MSC_VER < 1900
static __inline SDL_version GPU_GetCompiledVersion(void) static __inline SDL_version GPU_GetCompiledVersion(void)
#else #else
static inline SDL_version GPU_GetCompiledVersion(void) static inline SDL_version GPU_GetCompiledVersion(void)
#endif #endif
#else
static inline SDL_version GPU_GetCompiledVersion(void)
#endif
{ {
SDL_version v = {SDL_GPU_VERSION_MAJOR, SDL_GPU_VERSION_MINOR, SDL_GPU_VERSION_PATCH}; SDL_version v = {SDL_GPU_VERSION_MAJOR, SDL_GPU_VERSION_MINOR, SDL_GPU_VERSION_PATCH};
return v; return v;