[algs] Call std::hash from hb_hash()

This commit is contained in:
Behdad Esfahbod 2022-01-10 15:04:47 -07:00
parent 74811c501d
commit 53847dba92
1 changed files with 5 additions and 1 deletions

View File

@ -36,6 +36,7 @@
#include <algorithm> #include <algorithm>
#include <initializer_list> #include <initializer_list>
#include <functional>
#include <new> #include <new>
/* /*
@ -215,7 +216,10 @@ struct
private: private:
template <typename T> constexpr auto template <typename T> constexpr auto
impl (const T& v, hb_priority<1>) const HB_RETURN (uint32_t, hb_deref (v).hash ()) impl (const T& v, hb_priority<2>) const HB_RETURN (uint32_t, hb_deref (v).hash ())
template <typename T> constexpr auto
impl (const T& v, hb_priority<1>) const HB_RETURN (uint32_t, std::hash<decltype (hb_deref (v))>{} (hb_deref (v)))
template <typename T, template <typename T,
hb_enable_if (std::is_integral<T>::value)> constexpr auto hb_enable_if (std::is_integral<T>::value)> constexpr auto