The alloc_size attribute isn't supported in clang 3.x
parent
6b5855e990
commit
5dd07a5773
|
@ -182,7 +182,7 @@
|
||||||
#endif /* SDL_MALLOC not defined */
|
#endif /* SDL_MALLOC not defined */
|
||||||
|
|
||||||
#ifndef SDL_ALLOC_SIZE
|
#ifndef SDL_ALLOC_SIZE
|
||||||
#if defined(__clang__) || (defined(__GNUC__) && (__GNUC__ > 4 || (__GNUC__ == 4 && __GNUC_MINOR__ >= 3)))
|
#if (defined(__clang__) && __clang_major__ >= 4) || (defined(__GNUC__) && (__GNUC__ > 4 || (__GNUC__ == 4 && __GNUC_MINOR__ >= 3)))
|
||||||
#define SDL_ALLOC_SIZE(p) __attribute__((alloc_size(p)))
|
#define SDL_ALLOC_SIZE(p) __attribute__((alloc_size(p)))
|
||||||
#elif defined(_MSC_VER)
|
#elif defined(_MSC_VER)
|
||||||
#define SDL_ALLOC_SIZE(p)
|
#define SDL_ALLOC_SIZE(p)
|
||||||
|
@ -192,7 +192,7 @@
|
||||||
#endif /* SDL_ALLOC_SIZE not defined */
|
#endif /* SDL_ALLOC_SIZE not defined */
|
||||||
|
|
||||||
#ifndef SDL_ALLOC_SIZE2
|
#ifndef SDL_ALLOC_SIZE2
|
||||||
#if defined(__clang__) || (defined(__GNUC__) && (__GNUC__ > 4 || (__GNUC__ == 4 && __GNUC_MINOR__ >= 3)))
|
#if (defined(__clang__) && __clang_major__ >= 4) || (defined(__GNUC__) && (__GNUC__ > 4 || (__GNUC__ == 4 && __GNUC_MINOR__ >= 3)))
|
||||||
#define SDL_ALLOC_SIZE2(p1, p2) __attribute__((alloc_size(p1, p2)))
|
#define SDL_ALLOC_SIZE2(p1, p2) __attribute__((alloc_size(p1, p2)))
|
||||||
#elif defined(_MSC_VER)
|
#elif defined(_MSC_VER)
|
||||||
#define SDL_ALLOC_SIZE2(p1, p2)
|
#define SDL_ALLOC_SIZE2(p1, p2)
|
||||||
|
|
Loading…
Reference in New Issue