Honeycomb  0.1
Component-Model Framework
Classes | Namespaces | Macros | Functions
Allocator.h File Reference
#include "Honey/Core/Meta.h"
Include dependency graph for Allocator.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

class  honey::Allocator< Subclass, T >
 std::allocator compatible allocator More...
 
struct  honey::Allocator< Subclass, T >::rebind< U >
 
class  honey::AllocatorObject< Alloc >
 Objects that inherit from this class will use Alloc for new/delete ops. More...
 
struct  honey::DefaultAllocator< T, class >
 Returns T::Allocator<T> if available, otherwise std::allocator<T> More...
 
struct  honey::DefaultAllocator< T[], std::true_type >
 
struct  honey::DefaultAllocator< T, typename mt::True< typename T::template Allocator< T > >::type >
 
struct  honey::finalize< T, Alloc >
 Functor to delete a pointer. More...
 
struct  honey::finalize< T[], std::allocator< T > >
 Specialization for array. More...
 
struct  honey::finalize< void, std::allocator< void > >
 Specialization for void. More...
 

Namespaces

 honey
 Global Honeycomb namespace.
 

Macros

#define new_   new (__FILE__, __LINE__)
 Global new_, use in place of new keyword to provide allocator with debug info. More...
 

Functions

void * operator new (size_t size, const char *srcFile, int srcLine)
 
void * operator new[] (size_t size, const char *srcFile, int srcLine)
 
template<class T >
T * honey::alloc (szt count=1)
 Allocate memory for count number of T objects. Objects are not constructed. More...
 
template<class T >
void honey::free (T *&p)
 Deallocate memory and set pointer to null. Object is not destroyed. More...
 
template<class T >
void honey::free (T *const &p)
 
template<class T >
T * honey::alignFloor (T *p, szt bytes)
 Align a pointer to the previous byte boundary bytes. Does nothing if p is already on boundary. Alignment must be a power of two. More...
 
template<class T >
T * honey::alignCeil (T *p, szt bytes)
 Align a pointer to the next byte boundary bytes. Does nothing if p is already on boundary. Alignment must be a power of two. More...
 
template<class T , class Alloc >
T * honey::allocAligned (szt count, szt align_, Alloc &&a)
 Allocate memory with alignment. Alignment must be a power of two. Allocator element type must be int8. More...
 
template<class T >
T * honey::allocAligned (szt count, szt align)
 Allocate memory with alignment using default allocator. More...
 
template<class T , class Alloc >
void honey::freeAligned (T *p, Alloc &&a)
 Deallocate aligned memory. Allocator element type must be int8. More...
 
template<class T >
void honey::freeAligned (T *p)
 Deallocate aligned memory using default allocator. More...
 
template<class T >
void honey::delete_ (T *&p)
 Destruct object, free memory and set pointer to null. More...
 
template<class T >
void honey::delete_ (T *const &p)
 
template<class T , class Alloc >
void honey::delete_ (T *&p, Alloc &&a)
 Destruct object, free memory using allocator and set pointer to null. More...
 
template<class T , class Alloc >
void honey::delete_ (T *const &p, Alloc &&a)
 
template<class T >
void honey::deleteArray (T *&p)
 Destruct all array objects, free memory and set pointer to null. More...
 
template<class T >
void honey::deleteArray (T *const &p)