You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository was archived by the owner on Apr 4, 2020. It is now read-only.
It seems to me that the removing a node from the tree does not adjust the IDs of the nodes. This would be okay, if only adding a child to a node did not use length as a value for the ID of a new node being created.
E.G.
root with 3 children, (A,B,C)
ID A: 0/0
ID B: 0/1
ID C: 0/2
length:3
Calling B.remove() will leave the tree in this state
root with 2 children, (A,C)
ID A: 0/0
ID C: 0/2
length:2
Adding a new node D:
root with 3 children, (A,C,D)
ID A: 0/0
ID C: 0/2
ID D: 0/2
length:3
This results in element D disappearing from iterations over the tree.
Hi all,
It seems to me that the removing a node from the tree does not adjust the IDs of the nodes. This would be okay, if only adding a child to a node did not use length as a value for the ID of a new node being created.
E.G.
root with 3 children, (A,B,C)
ID A: 0/0
ID B: 0/1
ID C: 0/2
length:3
Calling B.remove() will leave the tree in this state
root with 2 children, (A,C)
ID A: 0/0
ID C: 0/2
length:2
Adding a new node D:
root with 3 children, (A,C,D)
ID A: 0/0
ID C: 0/2
ID D: 0/2
length:3
This results in element D disappearing from iterations over the tree.