mirror of
https://github.com/fmtlib/fmt.git
synced 2024-12-03 06:41:03 +00:00
use simplified void_t
for all compilers other than gcc 4.x (#2160)
This commit is contained in:
parent
835b910e7d
commit
d8b9254301
@ -1379,10 +1379,14 @@ template <typename T> struct formattable : std::false_type {};
|
|||||||
|
|
||||||
namespace detail {
|
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.
|
// A workaround for gcc 4.8 to make void_t work in a SFINAE context.
|
||||||
template <typename... Ts> struct void_t_impl { using type = void; };
|
template <typename... Ts> struct void_t_impl { using type = void; };
|
||||||
template <typename... Ts>
|
template <typename... Ts>
|
||||||
using void_t = typename detail::void_t_impl<Ts...>::type;
|
using void_t = typename detail::void_t_impl<Ts...>::type;
|
||||||
|
#else
|
||||||
|
template <typename...> using void_t = void;
|
||||||
|
#endif
|
||||||
|
|
||||||
template <typename It, typename T, typename Enable = void>
|
template <typename It, typename T, typename Enable = void>
|
||||||
struct is_output_iterator : std::false_type {};
|
struct is_output_iterator : std::false_type {};
|
||||||
|
Loading…
Reference in New Issue
Block a user