diff options
| -rw-r--r-- | include/xxhash.h | 8 |
1 files changed, 3 insertions, 5 deletions
diff --git a/include/xxhash.h b/include/xxhash.h index fbd1aab9ac..c17521f99f 100644 --- a/include/xxhash.h +++ b/include/xxhash.h @@ -631,14 +631,12 @@ introduced in CPP17 and C23. CPP17 : https://en.cppreference.com/w/cpp/language/attributes/fallthrough C23 : https://en.cppreference.com/w/c/language/attributes/fallthrough */ -#if XXH_HAS_C_ATTRIBUTE(x) -# define XXH_FALLTHROUGH [[fallthrough]] -#elif XXH_HAS_CPP_ATTRIBUTE(x) +#if XXH_HAS_C_ATTRIBUTE(fallthrough) || XXH_HAS_CPP_ATTRIBUTE(fallthrough) # define XXH_FALLTHROUGH [[fallthrough]] #elif XXH_HAS_ATTRIBUTE(__fallthrough__) -# define XXH_FALLTHROUGH __attribute__ ((fallthrough)) +# define XXH_FALLTHROUGH __attribute__ ((__fallthrough__)) #else -# define XXH_FALLTHROUGH +# define XXH_FALLTHROUGH /* fallthrough */ #endif /*! |
