From d8b92543017053a2b2c5ca901ea310e20690b137 Mon Sep 17 00:00:00 2001 From: Alexey Ochapov Date: Wed, 3 Mar 2021 01:42:27 +0300 Subject: [PATCH] use simplified `void_t` for all compilers other than gcc 4.x (#2160) --- include/fmt/core.h | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/include/fmt/core.h b/include/fmt/core.h index 94b31f71..7b2b2a43 100644 --- a/include/fmt/core.h +++ b/include/fmt/core.h @@ -1379,10 +1379,14 @@ template struct formattable : std::false_type {}; namespace detail { +#if FMT_GCC_VERSION && FMT_GCC_VERSION < 500 // A workaround for gcc 4.8 to make void_t work in a SFINAE context. template struct void_t_impl { using type = void; }; template using void_t = typename detail::void_t_impl::type; +#else +template using void_t = void; +#endif template struct is_output_iterator : std::false_type {};