mirror of
https://github.com/fmtlib/fmt.git
synced 2024-12-25 06:21:00 +00:00
Workaround 'cannot call member function without object' error on gcc 4.9
This commit is contained in:
parent
f72a905eb3
commit
3c24052cf1
@ -950,8 +950,9 @@ template <typename Context> struct arg_mapper {
|
|||||||
FMT_ENABLE_IF(std::is_enum<T>::value &&
|
FMT_ENABLE_IF(std::is_enum<T>::value &&
|
||||||
!has_formatter<T, Context>::value &&
|
!has_formatter<T, Context>::value &&
|
||||||
!has_fallback_formatter<T, Context>::value)>
|
!has_fallback_formatter<T, Context>::value)>
|
||||||
FMT_CONSTEXPR auto map(const T& val) -> decltype(
|
FMT_CONSTEXPR auto map(const T& val)
|
||||||
map(static_cast<typename std::underlying_type<T>::type>(val))) {
|
-> decltype(std::declval<arg_mapper>().map(
|
||||||
|
static_cast<typename std::underlying_type<T>::type>(val))) {
|
||||||
return map(static_cast<typename std::underlying_type<T>::type>(val));
|
return map(static_cast<typename std::underlying_type<T>::type>(val));
|
||||||
}
|
}
|
||||||
template <typename T,
|
template <typename T,
|
||||||
|
Loading…
Reference in New Issue
Block a user