TreeNode.removeTreeNode

Removes the given node, that must be present before this call. This is messier than typical red-black deletion code because we cannot swap the contents of an interior node with a leaf successor that is pinned by "next" pointers that are accessible independently during traversal. So instead we swap the tree linkages. If the current tree appears to have too few nodes, the bin is converted back to a plain bin. (The test triggers somewhere between 2 and 6 nodes, depending on tree structure).

class TreeNode(K, V)
final
void
removeTreeNode
(
HashMap!(K, V) map
,
HashMapNode!(K, V)[] tab
,
bool movable
)

Meta