GNU libavl 2.0.1
Author: Ben Pfaff

4.9.3.10 Replacing the Current Item |

    75. <BST traverser replacement function 75> =
    void *
    bst_t_replace (struct bst_traverser *trav, void *new)
    {
      void *old;

      assert (trav != NULL && trav->bst_node != NULL && new != NULL);
      old = trav->bst_node->bst_data;
      trav->bst_node->bst_data = new;
      return old;
    }

This code is included in 63, 178, 268, 395, 502, and 546.

4.9.3.9 Getting the Current Item | 4.9.3 Better Iterative Traversal | 4.10 Copying