void DLL_Insert( DL_List * l, DLL_Node * Prev, void * Data ) { DLL_Node * n; assert( l ); n = AllocatorAllocate( l->NodeAllocator ); assert( n ); n->Data = Data; Attach( l, n, Prev ); }
NAMESPACE_CORE_BEGIN void HashBase::AllocateBuckets(unsigned size, unsigned numBuckets) { if (this->ptrs) Deallocate(this->ptrs); HashNodeBase** ptrs = static_cast<HashNodeBase**>(AllocatorAllocate(AllocatorGetHeap(), (numBuckets + 2)*sizeof(HashNodeBase*), 0)); unsigned* data = reinterpret_cast<unsigned*>(ptrs); data[0] = size; data[1] = numBuckets; this->ptrs = ptrs; ResetPtrs(); }
static void* ENET_CALLBACK enet_custom_malloc(size_t size) { return AllocatorAllocate(gs_NetworkAllocator, size, 0); }