Lines Matching defs:neighbor
698 * neighbor node. That node will have at most 1 child. Note this
701 * As an optimization, we choose the greater neighbor if the tree
702 * is right heavy, otherwise the left neighbor. This reduces the
830 void *neighbor;
832 ASSERT(((neighbor = AVL_NEXT(t, obj)) == NULL) ||
833 (t->avl_compar(obj, neighbor) <= 0));
835 neighbor = AVL_PREV(t, obj);
836 if ((neighbor != NULL) && (t->avl_compar(obj, neighbor) < 0)) {
847 void *neighbor;
849 ASSERT(((neighbor = AVL_PREV(t, obj)) == NULL) ||
850 (t->avl_compar(obj, neighbor) >= 0));
852 neighbor = AVL_NEXT(t, obj);
853 if ((neighbor != NULL) && (t->avl_compar(obj, neighbor) > 0)) {
864 void *neighbor;
866 neighbor = AVL_PREV(t, obj);
867 if ((neighbor != NULL) && (t->avl_compar(obj, neighbor) < 0)) {
872 neighbor = AVL_NEXT(t, obj);
873 if ((neighbor != NULL) && (t->avl_compar(obj, neighbor) > 0)) {