cyaml · Section 3
cyaml_list_remove
NAME
cyaml_list_remove - remove and free a list element by index
LIBRARY
C Collections (libccollections, -lccollections)
SYNOPSIS
#include <ccollections/cyaml.h> ccol_retval cyaml_list_remove(cyaml seq, size_t index);
DESCRIPTION
Removes the element at position index from the list node seq and frees it together with everything below it. The elements after index move one position to the left, so the call costs O(n) in the number of elements that follow index.
RETURN VALUE
ccol_success - the element was removed and freed.
ccol_invalid_args - seq is NULL, seq is not a CYAML_LIST, or index
is out of bounds.
SEE ALSO
cyaml_list_push(3), cyaml_list_get(3), cyaml_dictionary_remove(3)