AK: Remove unused Jakt methods

This commit is contained in:
Timothy Flynn 2025-05-10 16:10:18 -04:00 committed by Tim Flynn
commit e2b863ed3f
Notes: github-actions[bot] 2025-05-11 01:21:31 +00:00
2 changed files with 3 additions and 13 deletions

View file

@ -22,6 +22,7 @@ namespace AK {
class StringView {
public:
ALWAYS_INLINE constexpr StringView() = default;
ALWAYS_INLINE constexpr StringView(char const* characters, size_t length)
: m_characters(characters)
, m_length(length)
@ -29,24 +30,20 @@ public:
if (!is_constant_evaluated())
VERIFY(!Checked<uintptr_t>::addition_would_overflow(reinterpret_cast<uintptr_t>(characters), length));
}
ALWAYS_INLINE StringView(unsigned char const* characters, size_t length)
: m_characters(reinterpret_cast<char const*>(characters))
, m_length(length)
{
VERIFY(!Checked<uintptr_t>::addition_would_overflow(reinterpret_cast<uintptr_t>(characters), length));
}
ALWAYS_INLINE StringView(ReadonlyBytes bytes)
: m_characters(reinterpret_cast<char const*>(bytes.data()))
, m_length(bytes.size())
{
}
// Note: This is here for Jakt.
ALWAYS_INLINE static StringView from_string_literal(StringView string)
{
return string;
}
StringView(ByteBuffer const&);
StringView(String const&);
StringView(FlyString const&);