Esme Povirk (@madewokherd) commented about dlls/uiautomationcore/tests/uiautomation.c:
+ SAFEARRAY *out_req, *offsets, *tree_structs; + struct node_provider_desc exp_node_desc[7]; + struct UiaPropertyCondition prop_cond[2]; + struct UiaCacheRequest cache_req; + struct UiaFindParams find_params; + const WCHAR *exp_tree_struct[7]; + HUIANODE node, node2; + int exp_offset[6]; + HRESULT hr; + VARIANT v; + + CoInitializeEx(NULL, COINIT_MULTITHREADED); + + set_provider_root_and_parent(&Provider, &Provider, NULL); + set_provider_children(&Provider, &Provider_child, &Provider_child2); + set_provider_siblings(&Provider, NULL, NULL); This is still including each individual link which seems redundant and potentially inconsistent. What I had in mind was an add_child function that would update the parent's last_child link, the parent's first_child link if necessary, the child's parent link, the child's previous_sibling link if necessary, and the previous sibling's next_sibling link.
-- https://gitlab.winehq.org/wine/wine/-/merge_requests/1249#note_14095