Improve FMT_ALWAYS_INLINE

1. FMT_ALWAYS_INLINE should imply inline; otherwise, there might be
   linkage problems
2. Add specialization for MSVC (__forceinline)
This commit is contained in:
Junekey Jeon 2020-09-17 12:04:50 -07:00
parent 7e6827521a
commit 6af2e44c24

View File

@ -870,8 +870,10 @@ template <> int count_digits<4>(detail::fallback_uintptr n);
#if FMT_GCC_VERSION || FMT_CLANG_VERSION
# define FMT_ALWAYS_INLINE inline __attribute__((always_inline))
#elif FMT_MSC_VER
# define FMT_ALWAYS_INLINE __forceinline
#else
# define FMT_ALWAYS_INLINE
# define FMT_ALWAYS_INLINE inline
#endif
#ifdef FMT_BUILTIN_CLZ