Caller must apply constructor, using normal syntax for new, but with friend template, as follows:
obj = new (*pool) T(args);
To delete an object, client uses
pool->destroy_object(obj)
Definition at line 289 of file block_alloc.h.
Public Types | |
typedef block_pool< T, dynpool, MaxBytes > | Pool |
Public Member Functions | |
void | recycle () |
Let the zombies (released-but-not-yet-reusable chips) become usable again. | |
size_t | freelist_size () const |
Static Public Member Functions | |
static void | destroy_object (T *ptr) |