From 4517b8759c590ea515c8f59dbb17312557bfe7f1 Mon Sep 17 00:00:00 2001 From: cancel Date: Wed, 8 Jan 2020 06:08:25 +0900 Subject: [PATCH] Cleanup no attrib warning in clang --- thirdparty/sdd.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/thirdparty/sdd.c b/thirdparty/sdd.c index 9970648..a926dea 100644 --- a/thirdparty/sdd.c +++ b/thirdparty/sdd.c @@ -52,7 +52,11 @@ typedef struct sdd { #define SDD_HDR(s) ((sdd_header *)s - 1) #if defined(__GNUC__) || defined(__clang__) +#if __has_attribute(noinline) && __has_attribute(noclone) #define SDD_NOINLINE __attribute__((noinline, noclone)) +#else +#define SDD_NOINLINE __attribute__((noinline)) +#endif #elif defined(_MSC_VER) #define SDD_NOINLINE __declspec(noinline) #else