include: vlc_list.hpp: add C++ wrapper for vlc_list
vlc_list.h provides struct vlc_list which is mostly designed to be used in C code to provide doubly-linked chained list, which is already exposed in C++ in an unintrusive way through std::list<> and work is still done in the standard[^1] to try to submit intrusive list support. However, some part of the public libvlccore API is exposing objects with vlc_list members, which enforce their usage in the C++ code without more standard alternative option. This MR adds a C++ wrapper around the vlc_list structure to be able to loop through vlc_list without the C macros. It has some limitations to avoid exploding the implementation and type complexity, in particular when it comes to the list<T>::reverse_list type which doesn't support operations (push_front, push_back, erase). However, the base list<T> type will support those using the same iterators. [^1]: https://www.open-std.org/JTC1/SC22/WG21/docs/papers/2016/p0406r1.html Refs #28507 Co-authored-by:Pierre Lamot <pierre@videolabs.io>
parent
fd1444e8
No related branches found
No related tags found
Loading