feat(ll): provide a ds_*ll_init func for consistency
This commit is contained in:
14
ds.h
14
ds.h
@@ -24,6 +24,20 @@ typedef struct {
|
||||
|
||||
#define ds_ll_foreach(t, ll) for (t *cur = ll; cur; cur = cur->next)
|
||||
|
||||
/**
|
||||
* @brief initialize a new singly linked list
|
||||
*
|
||||
* @return the new linked list
|
||||
*/
|
||||
ds_sll_t *ds_sll_init(void);
|
||||
|
||||
/**
|
||||
* @brief initialize a new doubly linked list
|
||||
*
|
||||
* @return the new linked list
|
||||
*/
|
||||
ds_dll_t *ds_dll_init(void);
|
||||
|
||||
/**
|
||||
* @brief create a new allocated node for a singly linked list
|
||||
*
|
||||
|
Reference in New Issue
Block a user