Apply 2746 fix for NVidia compiler also (#2770)

This commit is contained in:
Greg Sjaardema 2022-02-16 13:04:16 -07:00 committed by GitHub
parent a1ea3e015b
commit 70de324aa8
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -1431,7 +1431,7 @@ template <typename Context> struct arg_mapper {
!std::is_const<remove_reference_t<T>>::value ||
has_fallback_formatter<U, char_type>::value> {};
#if (FMT_MSC_VER != 0 && FMT_MSC_VER < 1910) || FMT_ICC_VERSION != 0
#if (FMT_MSC_VER != 0 && FMT_MSC_VER < 1910) || FMT_ICC_VERSION != 0 || FMT_NVCC != 0
// Workaround a bug in MSVC and Intel (Issue 2746).
template <typename T> FMT_CONSTEXPR FMT_INLINE auto do_map(T&& val) -> T& {
return val;