mirror of
https://github.com/fmtlib/fmt.git
synced 2025-06-25 09:21:41 +02:00
Make parameter basic_memory_buffer<char, SIZE>& buf of to_string const
This commit is contained in:
committed by
Victor Zverovich
parent
735d4cc05e
commit
873670ba3f
@ -891,7 +891,7 @@ class basic_memory_buffer : public detail::buffer<T> {
|
||||
using memory_buffer = basic_memory_buffer<char>;
|
||||
|
||||
template <size_t SIZE>
|
||||
FMT_NODISCARD auto to_string(basic_memory_buffer<char, SIZE>& buf)
|
||||
FMT_NODISCARD auto to_string(const basic_memory_buffer<char, SIZE>& buf)
|
||||
-> std::string {
|
||||
auto size = buf.size();
|
||||
detail::assume(size < std::string().max_size());
|
||||
|
Reference in New Issue
Block a user