2 ms·
struct Node does not need first_child pointer when it is TextNode/CommentNodes/etc. as they are just terminals. Yet text node here <div>text</text> do
by c-smile 10y ago
struct Node does not need first_child pointer when it is TextNode/CommentNodes/etc. as they are just terminals.
Yet text node here
<div>text</text>
does not need next/previous pointers as it is lone child.
In case of DOM tree children-vector case takes always less than "children-dl-list" case. With only one exception - element with single child node when size of memory needed is the same as in "children-dl-list".