mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-08-28 13:18:19 +00:00
AK+Kernel: StringView hash map Traits should not set peek type to String
This typo / bug in the Traits<T> implementation for StringView caused AK::HashMap methods to return a `String` when looking up values out of a hash map of type HashTable<StringView,StringView>. This change fixes the typo, and fixes the only consumer, the kernel Commandline class.
This commit is contained in:
parent
9bdb44c5d2
commit
e9d8f158a1
Notes:
sideshowbarker
2024-07-18 05:33:54 +09:00
Author: https://github.com/bgianfo
Commit: e9d8f158a1
Pull-request: https://github.com/SerenityOS/serenity/pull/9469
Reviewed-by: https://github.com/alimpfard ✅
3 changed files with 8 additions and 8 deletions
|
@ -228,7 +228,7 @@ private:
|
|||
};
|
||||
|
||||
template<>
|
||||
struct Traits<StringView> : public GenericTraits<String> {
|
||||
struct Traits<StringView> : public GenericTraits<StringView> {
|
||||
static unsigned hash(const StringView& s) { return s.hash(); }
|
||||
};
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue