summaryrefslogtreecommitdiff
path: root/AK/Traits.h
diff options
context:
space:
mode:
Diffstat (limited to 'AK/Traits.h')
-rw-r--r--AK/Traits.h6
1 files changed, 6 insertions, 0 deletions
diff --git a/AK/Traits.h b/AK/Traits.h
index 9d04f1d367..e3b7c1ac66 100644
--- a/AK/Traits.h
+++ b/AK/Traits.h
@@ -55,6 +55,12 @@ struct Traits<unsigned> : public GenericTraits<unsigned> {
};
template<>
+struct Traits<u8> : public GenericTraits<u8> {
+ static constexpr bool is_trivial() { return true; }
+ static unsigned hash(u8 u) { return int_hash(u); }
+};
+
+template<>
struct Traits<u16> : public GenericTraits<u16> {
static constexpr bool is_trivial() { return true; }
static unsigned hash(u16 u) { return int_hash(u); }