change XNode children to a vector.
This means the order of children is preserved. It also means the name of each node isn't duplicated. This was an opportunity for an inconsistent XNode tree. Nodes can now be renamed after being inserted into a tree. Searching for children by name isn't efficient. Use attributes for that.
This commit is contained in:
@@ -232,8 +232,7 @@ namespace
|
||||
{
|
||||
pNode = queue.back();
|
||||
queue.pop_back();
|
||||
FOREACH_Child( pNode, pChild )
|
||||
queue.push_back( pChild );
|
||||
queue.insert( queue.end(), pNode->m_childs.begin(), pNode->m_childs.end() );
|
||||
|
||||
/* Source file, for error messages: */
|
||||
pNode->AppendAttr( "_Source", sFile );
|
||||
|
||||
Reference in New Issue
Block a user