From e445b0ddbd73ea61f0c838a8536d0ef6a461954a Mon Sep 17 00:00:00 2001 From: Jordan Peck Date: Mon, 8 Apr 2024 16:55:40 +0100 Subject: [PATCH] Passthrough is_avalanching from std::hash --- include/ankerl/unordered_dense.h | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/include/ankerl/unordered_dense.h b/include/ankerl/unordered_dense.h index fd81e96..a5697cb 100644 --- a/include/ankerl/unordered_dense.h +++ b/include/ankerl/unordered_dense.h @@ -277,6 +277,15 @@ struct hash { } }; +template +struct hash::is_avalanching> { + using is_avalanching = void; + auto operator()(T const& obj) const noexcept(noexcept(std::declval>().operator()(std::declval()))) + -> uint64_t { + return std::hash{}(obj); + } +}; + template struct hash> { using is_avalanching = void;