diff --git a/AK/StringView.h b/AK/StringView.h index 4e8a652dec9..a1d4de9cbb7 100644 --- a/AK/StringView.h +++ b/AK/StringView.h @@ -57,6 +57,11 @@ public: , m_length(cstring ? __builtin_strlen(cstring) : 0) { } + ALWAYS_INLINE StringView(ReadonlyBytes bytes) + : m_characters(reinterpret_cast(bytes.data())) + , m_length(bytes.size()) + { + } StringView(const ByteBuffer&); StringView(const String&);