mirror of
https://github.com/NikitaIvanovV/ctpv.git
synced 2024-12-01 00:43:08 +01:00
773df4c35a
Use unrolled linked list instead of vector for storing text
20 lines
346 B
C
20 lines
346 B
C
#ifndef ULIST_H
|
|
#define ULIST_H
|
|
|
|
#include <stdlib.h>
|
|
|
|
/*
|
|
* Unrolled linked list
|
|
*/
|
|
|
|
typedef struct UList UList;
|
|
|
|
UList *ulist_new(size_t size, size_t cap);
|
|
void ulist_free(UList *l);
|
|
void ulist_append_arr(UList *l, void *arr, size_t len);
|
|
void ulist_append(UList *l, void *val);
|
|
void ulist_lock(UList *l);
|
|
void *ulist_unlock(UList *l);
|
|
|
|
#endif
|