42 template<
typename Pred>
52 if (base_type::empty())
59 base_type::to_linked_list();
60 node_pointer p_out = base_type::prune(pred);
66 node_pointer p_next = p_out->m_p_next_sibling;
67 p_out->m_p_l_child = p_out->m_p_next_sibling = p_out->m_p_prev_or_parent = 0;
69 other.push_imp(p_out);
74 node_pointer p_cur = base_type::m_p_root;
75 base_type::m_p_root = 0;
78 node_pointer p_next = p_cur->m_p_next_sibling;
79 p_cur->m_p_l_child = p_cur->m_p_next_sibling = p_cur->m_p_prev_or_parent = 0;
97 if (other.m_p_root == 0)
104 if (base_type::m_p_root == 0)
105 base_type::m_p_root = other.m_p_root;
106 else if (Cmp_Fn::operator()(base_type::m_p_root->m_value, other.m_p_root->m_value))
108 base_type::make_child_of(base_type::m_p_root, other.m_p_root);
110 base_type::m_p_root = other.m_p_root;
114 base_type::make_child_of(other.m_p_root, base_type::m_p_root);
118 base_type::m_size += other.m_size;
#define _GLIBCXX_DEBUG_ASSERT(_Condition)
Definition: debug.h:61
#define PB_DS_CLASS_C_DEC
Definition: bin_search_tree_.hpp:71
#define PB_DS_CLASS_T_DEC
Definition: bin_search_tree_.hpp:67
return(unsigned int) __res
#define PB_DS_ASSERT_NODE_CONSISTENT(_Node)
Definition: bin_search_tree_.hpp:402
#define PB_DS_ASSERT_VALID(X)
Definition: binary_heap_.hpp:324