|
@ -10,9 +10,9 @@ |
|
|
template<typename T> |
|
|
template<typename T> |
|
|
class unique_ptr { |
|
|
class unique_ptr { |
|
|
T* data; |
|
|
T* data; |
|
|
gp::allocator const& owner; |
|
|
|
|
|
|
|
|
gp::allocator& owner; |
|
|
|
|
|
|
|
|
unique_ptr(T* _data, gp::allocator const& _owner) |
|
|
|
|
|
|
|
|
unique_ptr(T* _data, gp::allocator& _owner) |
|
|
: data(data) |
|
|
: data(data) |
|
|
, owner(_owner) |
|
|
, owner(_owner) |
|
|
{} |
|
|
{} |
|
@ -64,9 +64,9 @@ template |
|
|
class shared_ptr { |
|
|
class shared_ptr { |
|
|
T* data; |
|
|
T* data; |
|
|
std::atomic_int* refcounter; |
|
|
std::atomic_int* refcounter; |
|
|
gp::allocator const& owner; |
|
|
|
|
|
|
|
|
gp::allocator& owner; |
|
|
|
|
|
|
|
|
shared_ptr(T* _data, gp::allocator const& _owner) |
|
|
|
|
|
|
|
|
shared_ptr(T* _data, gp::allocator& _owner) |
|
|
: data(data) |
|
|
: data(data) |
|
|
, owner(_owner) |
|
|
, owner(_owner) |
|
|
{} |
|
|
{} |
|
|