On Tue Sep 27 20:16:37 2022 +0000, Esme Povirk wrote:
I really don't think this needs to be a pointer. If there's going to be at most 1 entry per uia_node, and it doesn't need to outlive the uia_node, you can put the entry in there directly. You can use list_init() when creating uia_node and list_empty() to check if the entry is being used. (Though list_remove will leave the entry in an invalid state, and you'll have to init it again if you want that check to work afterwards.)
That'd make sense. I guess we could also apply this to `node_map_list_entry`, and rather than have custom list entry structures for each, just use the `struct uia_node` structure to store the information we need instead.