Lines Matching defs:internal
6571 // Instead, it should rely on its internal state to prevent
16350 /// length, and a capacity. The pointer points to an internal buffer `String`
16542 /// `String`s have an internal buffer to hold their data. The capacity is
16851 /// internal data structures.
19455 // Module with internal macros used by other modules (needs to be included before other modules).
25854 //! The internal iterator over the argument has not been advanced by the time
26216 //! Output will typically represent the internal state as faithfully as possible.
29579 Internal(internal) => internal.descend(),
29592 /// the node is internal.
29662 /// the matching child node, if `self` is an internal node.
29697 /// (if the node is internal) or where the key can be inserted.
29740 /// the matching child node, if `self` is an internal node.
29818 // - If the root node is internal, it must contain at least 1 element.
29982 Internal(internal) => {
29983 let mut out_tree = clone_subtree(internal.first_edge().descend());
29988 let mut in_edge = internal.first_edge();
33964 /// Given an internal edge handle, returns [`Result::Ok`] with a handle to the neighboring KV
33965 /// on the right side, which is either in the same internal node or in an ancestor node.
33966 /// If the internal edge is the last one in the tree, returns [`Result::Err`] with the root node.
34164 Internal(internal) => node = internal.first_edge().descend(),
34177 Internal(internal) => node = internal.last_edge().descend(),
34190 /// Visits leaf nodes and internal KVs in order of ascending keys, and also
34191 /// visits internal nodes as a whole in a depth first order, meaning that
34192 /// internal nodes precede their individual KVs and their child nodes.
34199 Internal(internal) => {
34200 visit(Position::Internal(internal));
34201 let mut edge = internal.first_edge();
34214 Internal(internal) => {
34215 visit(Position::Internal(internal));
34216 internal.first_edge()
35582 // i.e., a tree who's root is an internal node at height 1, with edges to leaf nodes.
35587 // i.e., a tree who's root is an internal node at height 2, with edges to more internal nodes.
35713 // - 1 element in internal root node with 2 children
35725 // - 1 element in internal root node with 2 children
35726 // - 6 elements in left internal child with 7 grandchildren
35728 // - 5 elements in right internal child with 6 grandchildren
37739 /// a root node that is internal, which the caller should pop from the map
37816 // The internal node may have been stolen from or merged. Go back right
37818 let mut internal = unsafe { left_hole.next_kv().ok().unwrap_unchecked() };
37819 let old_kv = internal.replace_kv(left_kv.0, left_kv.1);
37820 let pos = internal.next_leaf_edge();
37952 // since leaf edges are empty and need no data representation. In an internal node,
37970 /// The underlying representation of leaf nodes and part of the representation of internal nodes.
38011 /// The underlying representation of internal nodes. As with `LeafNode`s, these should be hidden
38014 /// node, allowing code to act on leaf and internal nodes generically without having to even check
38031 /// An invariant of internal nodes is that they have at least one
38054 // internal use of `NodeRef` because we stay completely generic over `K` and `V`.
38078 /// `NodeRef` points to an internal node, and when this is `LeafOrInternal` the
38110 /// The pointer to the leaf or internal node. The definition of `InternalNode`
38155 unsafe fn from_new_internal(internal: Box<InternalNode<K, V>>, height: usize) -> Self {
38157 let node = NonNull::from(Box::leak(internal)).cast();
38173 /// Exposes the data of an internal node.
38183 /// Borrows exclusive access to the data of an internal node.
38215 /// Exposes the leaf portion of any leaf or internal node.
38291 /// Exposes the leaf portion of any leaf or internal node in an immutable tree.
38346 /// Borrows exclusive access to the leaf portion of any leaf or internal node.
38353 /// Offers exclusive access to the leaf portion of any leaf or internal node.
38474 /// Adds a new internal node with a single edge pointing to the previous root node,
38480 // `self.borrow_mut()`, except that we just forgot we're internal now:
38484 /// Removes the internal root node, using its first child as the new root node.
38492 /// Panics if there is no internal level, i.e., if the root node is a leaf.
38498 // SAFETY: we asserted to be internal.
39058 /// around an internal key-value pair.
39106 Err(_) => unreachable!("empty internal node"),
39183 // of the node of this edge, thus above zero, so they are internal.
39829 while let Internal(internal) = cur_node.force() {
39831 let mut last_kv = internal.last_kv().consider_for_balancing();
41303 // SAFETY: The internal `IterMut` safety invariant is established because the
41496 // SAFETY: The internal `IterMut` safety invariant is established because the
42057 // and is at index zero in the internal buffer:
42494 /// Rearranges the internal storage of this deque so it is one contiguous
42501 /// Once the internal storage is contiguous, the [`as_slices`] and
46123 // internal helper trait for in-place iteration specialization.
46679 // The std-internal SourceIter/InPlaceIterable traits are only implemented by chains of
46776 // - unlike most internal iteration methods, it only takes a &mut self
47270 /// internal data structures. For example it is **not** safe
47408 /// internal data structures. For example it is **not** safe