Barrelfish
Functions
list.c File Reference

Barrelfish collections library list data structure. More...

Functions

void * collections_list_remove_if (collections_listnode *start, collections_list_predicate p, void *arg)
 
uint32_t collections_list_remove_if_all (collections_listnode *start, collections_list_predicate p, void *arg)
 

Detailed Description

Barrelfish collections library list data structure.

Function Documentation

void* collections_list_remove_if ( collections_listnode *  start,
collections_list_predicate  p,
void *  arg 
)

Remove the first item that matches the given predicate and return it.

Returns
The removed item.
uint32_t collections_list_remove_if_all ( collections_listnode *  start,
collections_list_predicate  p,
void *  arg 
)

Remove all the items that match the given predicate.

Returns
The number of items removed.