From 3fe4641d3a33a125285dd890b3a0c0ddf81f329f Mon Sep 17 00:00:00 2001 From: Tor Shepherd <49597791+torshepherd@users.noreply.github.com> Date: Sat, 13 Jul 2024 11:23:49 -0400 Subject: [PATCH] Add 2 more constexprs to fix compile error (#4065) --- include/fmt/base.h | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/include/fmt/base.h b/include/fmt/base.h index e3fc5c3e..d4a3474d 100644 --- a/include/fmt/base.h +++ b/include/fmt/base.h @@ -621,11 +621,12 @@ namespace detail { // to it, deducing Char. Explicitly convertible types such as the ones returned // from FMT_STRING are intentionally excluded. template ::value)> -auto to_string_view(const Char* s) -> basic_string_view { +constexpr auto to_string_view(const Char* s) -> basic_string_view { return s; } template ::value)> -auto to_string_view(const T& s) -> basic_string_view { +constexpr auto to_string_view(const T& s) + -> basic_string_view { return s; } template