diff --git a/include/fmt/core.h b/include/fmt/core.h index 02a389fa..091da657 100644 --- a/include/fmt/core.h +++ b/include/fmt/core.h @@ -296,10 +296,11 @@ template class basic_string_view { : data_(s), size_(std::char_traits::length(s)) {} /** Constructs a string reference from a ``std::basic_string`` object. */ - template - FMT_CONSTEXPR basic_string_view(const std::basic_string& s) - FMT_NOEXCEPT : data_(s.data()), - size_(s.size()) {} + template + FMT_CONSTEXPR basic_string_view( + const std::basic_string& s) FMT_NOEXCEPT + : data_(s.data()), + size_(s.size()) {} template < typename S, @@ -389,10 +390,10 @@ inline basic_string_view to_string_view(const Char* s) { return s; } -template +template inline basic_string_view to_string_view( - const std::basic_string& s) { - return {s.data(), s.size()}; + const std::basic_string& s) { + return s; } template