koutil
Loading...
Searching...
No Matches
koutil::container::is_template_hash Concept Reference

Concept to check if a type is a valid hash function for a given Key type. More...

#include <template_hash_array.h>

Concept definition

template<typename T, typename Key, typename ComptimeData>
concept koutil::container::is_template_hash = requires(T hash, const Key& key) {
requires std::is_trivially_constructible_v<T>;
{ hash.template hash<ComptimeData {}>(key) } -> std::same_as<std::size_t>;
}
Concept to check if a type is a valid hash function for a given Key type.
Definition template_hash_array.h:23

Detailed Description

Concept to check if a type is a valid hash function for a given Key type.

Template Parameters
TThe hash function type.
KeyThe key type.
ComptimeDataThe comptime data type.