Guard has_attribute usage

This commit is contained in:
Vladimir Serbinenko 2020-04-21 18:11:32 +02:00
parent 282e6d592d
commit 1ccbc51f62

View File

@ -13,10 +13,14 @@
#define STATIC_INLINE
#endif
#if defined(__has_attribute)
#if __has_attribute(always_inline)
#define ALWAYS_INLINE __attribute__((always_inline))
#else
#define ALWAYS_INLINE
#endif
#else
#define ALWAYS_INLINE
#endif
#endif // INLINE_H