From d2476c384527020cf145d359e8a2a5689e1c51cd Mon Sep 17 00:00:00 2001 From: Fabian Giesen Date: Thu, 8 Jul 2021 00:21:08 -0700 Subject: [PATCH] stb_sprintf: GCC compilation fix Fixes issue #1010. --- stb_sprintf.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/stb_sprintf.h b/stb_sprintf.h index e491425..82358a5 100644 --- a/stb_sprintf.h +++ b/stb_sprintf.h @@ -154,8 +154,8 @@ PERFORMANCE vs MSVC 2008 32-/64-bit (GCC is even slower than MSVC): #endif #endif #endif -#elif __GNUC__ >= 5 || (__GNUC__ == 4 && __GNUC_MINOR__ >= 8) - #if __SANITIZE_ADDRESS__ +#elif defined(__GNUC__) && (__GNUC__ >= 5 || (__GNUC__ == 4 && __GNUC_MINOR__ >= 8)) + #if defined(__SANITIZE_ADDRESS__) && __SANITIZE_ADDRESS__ #define STBSP__ASAN __attribute__((__no_sanitize_address__)) #endif #endif