From e5acc1eaa7e342b64ccfaaef5ea502cd623e41d5 Mon Sep 17 00:00:00 2001 From: Steven Le Rouzic Date: Thu, 23 Jan 2025 00:17:27 +0100 Subject: Add string_builder --- asl/string.hpp | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'asl/string.hpp') diff --git a/asl/string.hpp b/asl/string.hpp index fbeffe5..4750cd5 100644 --- a/asl/string.hpp +++ b/asl/string.hpp @@ -11,6 +11,13 @@ class string { buffer m_buffer; + explicit constexpr string(buffer&& buffer) : + m_buffer{ASL_MOVE(buffer)} + {} + + template + friend class string_builder; + public: constexpr string() requires default_constructible = default; explicit constexpr string(Allocator allocator) : m_buffer{ASL_MOVE(allocator)} {} -- cgit