fix(wavl): do not recursively fixup after delete
Signed-off-by: Matej Focko <mfocko@redhat.com>
This commit is contained in:
parent
2433928d36
commit
0882e6575d
1 changed files with 1 additions and 5 deletions
6
wavl.py
6
wavl.py
|
@ -159,10 +159,6 @@ class WAVLTree(AVLTree[T]):
|
|||
def _delete_rebalance(
|
||||
self, node: Optional[Node[T]], parent: Optional[Node[T]]
|
||||
) -> None:
|
||||
# FIXME: Do not go all the way up, just to the replaced nodes and then
|
||||
# check if rank rule is broken.
|
||||
while node or parent:
|
||||
self.__delete_fixup(node, parent)
|
||||
node, parent = parent, (parent.parent if parent else None)
|
||||
self.__delete_fixup(node, parent)
|
||||
|
||||
# endregion DeleteRebalance
|
||||
|
|
Loading…
Reference in a new issue