Not to mention that they insist on calling every entry of the list a "list head", which makes no sense (hysterical raisins, maybe?). The structure is made of a uniform loop of entries, one of which is used as the actual head & tail, or entry point into the structure.
antonvs|8 months ago
Disclaimer: I haven’t looked at this author’s code, just pointing out that list nodes that consist of (head, tail) are a common pattern with a clear rationale.
el_pollo_diablo|8 months ago
The intrusive, mutable, doubly-linked loops with reference semantics under discussion are quite different. Although all entries behave identically in the structure itself, one of them is _used_ differently, as a standalone anchor point, while the others are embedded in the list's "elements".
RustyRussell|8 months ago
See https://github.com/rustyrussell/ccan/blob/master/ccan/list/_...
el_pollo_diablo|8 months ago
unknown|8 months ago
[deleted]