aboutsummaryrefslogtreecommitdiff
path: root/src/DI/allocation.tpp
blob: 245ce9994d088e583c0da2fc270243e242936d5e (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
#pragma once

#include "allocation.hpp"

template <class Allocator>
AllocDestructor<Allocator>::AllocDestructor(Allocator &allocator,
											Size alloc_size) noexcept
	: _allocator(allocator), _size(alloc_size)
{
}

template <class Allocator>
void AllocDestructor<Allocator>::operator()(Pointer ptr) noexcept
{
	_alloc_traits::deallocate(_allocator, ptr, _size);
}