7#ifndef SE_COMMON_BOUNDED_VECTOR_HPP
8#define SE_COMMON_BOUNDED_VECTOR_HPP
22template<
typename T, std::
size_t N>
44 throw std::bad_alloc();
54 template<
typename U, std::
size_t M>
62 template<
typename U, std::
size_t M>
65 return !(*
this ==
rhs);
78template<
typename T, std::
size_t N>
An allocator using a static array of N elements of type T.
Definition bounded_vector.hpp:23
T * allocate(std::size_t n)
Definition bounded_vector.hpp:41
std::true_type propagate_on_container_move_assignment
Definition bounded_vector.hpp:31
T value_type
Definition bounded_vector.hpp:29
bool operator==(const ArrayAllocator< U, M > &rhs)
Definition bounded_vector.hpp:55
std::true_type propagate_on_container_swap
Definition bounded_vector.hpp:32
void deallocate(T *, std::size_t)
Definition bounded_vector.hpp:49
bool operator!=(const ArrayAllocator< U, M > &rhs)
Definition bounded_vector.hpp:63
std::true_type propagate_on_container_copy_assignment
Definition bounded_vector.hpp:30
static constexpr std::size_t capacity
Definition bounded_vector.hpp:34
constexpr bool is_power_of_two(const T x)
Helper wrapper to allocate and de-allocate octants in the octree.
Definition bounded_vector.hpp:14
std::vector< T, detail::ArrayAllocator< T, N > > BoundedVector
A statically-allocated std::vector that can store at most N elements.
Definition bounded_vector.hpp:79
Definition bounded_vector.hpp:37