Skip to content

Commit

Permalink
fix: remove unused to_string_view overload in fmt >= 11.1
Browse files Browse the repository at this point in the history
  • Loading branch information
jdrouhard committed Jan 9, 2025
1 parent 7f8060d commit 2a470be
Showing 1 changed file with 1 addition and 13 deletions.
14 changes: 1 addition & 13 deletions include/spdlog/common.h
Original file line number Diff line number Diff line change
Expand Up @@ -364,19 +364,7 @@ SPDLOG_CONSTEXPR_FUNC spdlog::wstring_view_t to_string_view(spdlog::wstring_view
}
#endif

#ifndef SPDLOG_USE_STD_FORMAT
#if FMT_VERSION >= 110100
template <typename T, typename... Args>
inline fmt::basic_string_view<T> to_string_view(fmt::basic_format_arg<T> fmt) {
return fmt;
}
#else
template <typename T, typename... Args>
inline fmt::basic_string_view<T> to_string_view(fmt::basic_format_string<T, Args...> fmt) {
return fmt;
}
#endif
#elif __cpp_lib_format >= 202207L
#if defined(SPDLOG_USE_STD_FORMAT) && __cpp_lib_format >= 202207L
template <typename T, typename... Args>
SPDLOG_CONSTEXPR_FUNC std::basic_string_view<T> to_string_view(
std::basic_format_string<T, Args...> fmt) SPDLOG_NOEXCEPT {
Expand Down

0 comments on commit 2a470be

Please sign in to comment.