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

Concept to check if a type is a valid allocator for a given bucket type. More...

#include <template_hash_array.h>

Concept definition

template<typename T, typename Bucket>
concept koutil::container::is_allocator = requires(T alloc, std::size_t n, Bucket* buckets) {
requires std::is_constructible_v<T>;
{ alloc.allocate(n) } -> std::same_as<Bucket*>;
{ alloc.deallocate(buckets, n) };
}
Concept to check if a type is a valid allocator for a given bucket type.
Definition template_hash_array.h:69

Detailed Description

Concept to check if a type is a valid allocator for a given bucket type.

Template Parameters
TThe allocator type.
BucketThe bucket type.