#pragma once #include template struct RebindAllocHelper { using type = typename Traits::template rebind_alloc; }; template class AllocDestructor { using _alloc_traits = std::allocator_traits; public: using Pointer = typename _alloc_traits::pointer; using Size = typename _alloc_traits::size_type; using pointer = Pointer; using size = Size; AllocDestructor(Allocator &allocator, Size alloc_size) noexcept; void operator()(Pointer ptr) noexcept; private: Allocator &_allocator; Size _size; }; #include "allocation.tpp"