(svn r26223) -Codechange: Silence some compile warnings about unititialized variables in the SSE blitters (MJP)
This commit is contained in:
17
src/stdafx.h
17
src/stdafx.h
@@ -490,4 +490,21 @@ static inline void free(const void *ptr)
|
||||
*/
|
||||
#define MAX_UVALUE(type) ((type)~(type)0)
|
||||
|
||||
#if defined(_MSC_VER) && !defined(_DEBUG)
|
||||
#define IGNORE_UNINITIALIZED_WARNING_START __pragma(warning(push)) __pragma(warning(disable:4700))
|
||||
#define IGNORE_UNINITIALIZED_WARNING_STOP __pragma(warning(pop))
|
||||
#elif defined(__GNUC__) && !defined(_DEBUG)
|
||||
#define HELPER0(x) #x
|
||||
#define HELPER1(x) HELPER0(GCC diagnostic ignored x)
|
||||
#define HELPER2(y) HELPER1(#y)
|
||||
#define IGNORE_UNINITIALIZED_WARNING_START \
|
||||
_Pragma("GCC diagnostic push") \
|
||||
_Pragma(HELPER2(-Wuninitialized)) \
|
||||
_Pragma(HELPER2(-Wmaybe-uninitialized))
|
||||
#define IGNORE_UNINITIALIZED_WARNING_STOP _Pragma("GCC diagnostic pop")
|
||||
#else
|
||||
#define IGNORE_UNINITIALIZED_WARNING_START
|
||||
#define IGNORE_UNINITIALIZED_WARNING_STOP
|
||||
#endif
|
||||
|
||||
#endif /* STDAFX_H */
|
||||
|
Reference in New Issue
Block a user