cbstmap · Section 3
cbstmap_destroy
NAME
cbstmap_destroy - destroy a BST map and set pointer to NULL
LIBRARY
C Collections (libccollections, -lccollections)
SYNOPSIS
#include <ccollections/cbstmap.h> cbstmap_destroy(cbm);
DESCRIPTION
Frees everything the BST map owns, its nodes, keys and values included, and then sets the map pointer to NULL.
PARAMETERS
cbm BST map to destroy (the macro sets it to NULL after it destroys
the map)
NOTES
Calling it with a NULL pointer is safe. The macro evaluates cbm exactly once. It must be a modifiable lvalue, such as a variable or an array element, so an expression with a side effect like handles[i++] destroys and clears exactly one element.