diff --git a/common/SmallString.h b/common/SmallString.h index c756dda389..00bfa76b3c 100644 --- a/common/SmallString.h +++ b/common/SmallString.h @@ -10,6 +10,7 @@ #include #include #include +#include #include #include #include @@ -177,7 +178,7 @@ public: __fi const char* end_ptr() const { return m_buffer + m_length; } // STL adapters - __fi void push_back(value_type&& val) { append(val); } + __fi void push_back(value_type val) { append(val); } // returns a string view for this string std::string_view view() const; @@ -413,7 +414,7 @@ __fi void SmallStringBase::format(fmt::format_string fmt, T&&... args) } \ \ template \ - auto format(const type& str, FormatContext& ctx) \ + auto format(const type& str, FormatContext& ctx) const \ { \ return fmt::format_to(ctx.out(), "{}", str.view()); \ } \