Bond 0.9
C++ Bond Runtime Library API Documentation
Loading...
Searching...
No Matches
Bond::Allocator::ObjectDeallocator< T > Struct Template Reference

A custom unique_ptr deleter that destroys an object by calling its destructor then freeing its memory by calling Allocator::Free rather than the delete operator. More...

#include <bond/systems/allocator.h>

Public Member Functions

 ObjectDeallocator (Allocator *allocator=nullptr)
void operator() (T *ptr)

Public Attributes

AllocatormAllocator

Detailed Description

template<typename T>
struct Bond::Allocator::ObjectDeallocator< T >

A custom unique_ptr deleter that destroys an object by calling its destructor then freeing its memory by calling Allocator::Free rather than the delete operator.

Constructor & Destructor Documentation

◆ ObjectDeallocator()

template<typename T>
Bond::Allocator::ObjectDeallocator< T >::ObjectDeallocator ( Allocator * allocator = nullptr)
inlineexplicit

Member Function Documentation

◆ operator()()

template<typename T>
void Bond::Allocator::ObjectDeallocator< T >::operator() ( T * ptr)
inline

Member Data Documentation

◆ mAllocator

template<typename T>
Allocator* Bond::Allocator::ObjectDeallocator< T >::mAllocator

The documentation for this struct was generated from the following file:
  • include/bond/systems/allocator.h