Use MEM_STATIC FORCE_INLINE_ATTR instead of FORCE_INLINE_TEMPLATE

It adds `__attribute__((unused))` for __GNUC__, to eliminate `-Werror=unused-function` error.
This commit is contained in:
animalize 2020-09-21 13:26:38 +08:00
parent 0a69a6b1ca
commit 2e5d73dd72

View File

@ -647,7 +647,8 @@ static const U64 prime8bytes = 0xCF1BBCDCB7A56463ULL;
static size_t ZSTD_hash8(U64 u, U32 h) { return (size_t)(((u) * prime8bytes) >> (64-h)) ; }
static size_t ZSTD_hash8Ptr(const void* p, U32 h) { return ZSTD_hash8(MEM_readLE64(p), h); }
FORCE_INLINE_TEMPLATE size_t ZSTD_hashPtr(const void* p, U32 hBits, U32 mls)
MEM_STATIC FORCE_INLINE_ATTR
size_t ZSTD_hashPtr(const void* p, U32 hBits, U32 mls)
{
switch(mls)
{