mirror of https://github.com/mpv-player/mpv
782e428284
This provides macros for managing intrusive doubly linked lists. There are many ways how to do those in a "generic" way in C. For example Solaris style lists are pretty nice: https://github.com/illumos/illumos-gate/blob/master/usr/src/uts/common/sys/list.h https://github.com/illumos/illumos-gate/blob/master/usr/src/common/list/list.c I even have an independent implementation of this, which could be ISC licensed. But I think it's easier to vomit ~100 lines of preprocessor garbage, which has a lower footprint, and I think it wins slightly on the side of type safety, simplicity, and ease of use, even if it doesn't look as magically nice. |
||
---|---|---|
.. | ||
bstr.c | ||
bstr.h | ||
charset_conv.c | ||
charset_conv.h | ||
ctype.h | ||
dispatch.c | ||
dispatch.h | ||
json.c | ||
json.h | ||
linked_list.h | ||
node.c | ||
node.h | ||
rendezvous.c | ||
rendezvous.h | ||
ring.c | ||
ring.h | ||
thread_pool.c | ||
thread_pool.h | ||
thread_tools.c | ||
thread_tools.h |