Next: , Previous: , Up: Top   [Contents][Index]


4 The standard allocator

Dynamic Constant: ccmem_allocator_t const * const ccmem_standard_allocator

Pointer to the standard memory allocator instance. This allocator uses the standard functions malloc(), realloc(), calloc() and free().

Function: void * ccmem_std_malloc (cce_destination_t L, size_t size)

Allocate memory in a way similar to the standard malloc(), using the standard allocator. If an error occurs: an exception is raised by jumping to the location L. This function never returns NULL.

Function: void * ccmem_std_realloc (cce_destination_t L, void * ptr, size_t newsize)

Reallocate memory in a way similar to the standard realloc(), using the standard allocator. If an error occurs: an exception is raised by jumping to the location L. This function never returns NULL. Only blocks of memory allocated using the standard allocator can be reallocated using this function.

Function: void * ccmem_std_calloc (cce_destination_t L, size_t count, size_t eltsize)

Allocate memory in a way similar to the standard calloc(), using the standard allocator. If an error occurs: an exception is raised by jumping to the location L. This function never returns NULL.

Function: void ccmem_std_free (void * ptr)

Release memory in a way similar to the standard free(), using the standard allocator.


Next: , Previous: , Up: Top   [Contents][Index]

This document describes version 0.2.2-devel.3 of CCMemory.