Toward a better list iterator for the kernel
Toward a better list iterator for the kernel
Posted Mar 10, 2022 22:13 UTC (Thu) by ppisa (subscriber, #67307)Parent article: Toward a better list iterator for the kernel
https://sourceforge.net/p/ulan/ulut/ci/master/tree/ulut/u...
This way you never use container_of directly and risk to use incorrect offset between list node location and start of containing structure is suppressed. For AVL, hashes and sorted arrays I have used other structures than kernel. The library provides even iterators which works over all of these basic types.
But macros which expands to the static inline functions are really huge. But reasonable compilers generate code better for these variants with CUSTom prefix than when generic functions with void pointers are used.
The library is base in many project, our RS485 multimaster project http://ulan.sourceforge.net/ , CAN and CANopen http://ortcan.sourceforge.net/ more instruments using inhouse our SmallToolKit graphic library https://gitlab.com/pikron/sw-base/suitk/-/wikis/home which has been used even is safety sensitive medical devices etc.
