AK: Use StringView as its own peek type

StringView is already a reference type, and copying it is cheap, so we
should use it as its own peek type.
This commit is contained in:
kleines Filmröllchen 2024-01-25 20:42:53 +01:00 committed by Ali Mohammad Pur
commit 8468fb9ae5
Notes: github-actions[bot] 2024-12-04 00:59:31 +00:00

View file

@ -377,6 +377,8 @@ private:
template<> template<>
struct Traits<StringView> : public DefaultTraits<StringView> { struct Traits<StringView> : public DefaultTraits<StringView> {
using PeekType = StringView;
using ConstPeekType = StringView;
static unsigned hash(StringView s) { return s.hash(); } static unsigned hash(StringView s) { return s.hash(); }
}; };