Skip to content

Commit

Permalink
Latest CAVL v3.1.0
Browse files Browse the repository at this point in the history
  • Loading branch information
serges147 committed Aug 24, 2024
1 parent f106cbc commit 43529b2
Showing 1 changed file with 6 additions and 5 deletions.
11 changes: 6 additions & 5 deletions lib/cavl/cavl.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -790,15 +790,16 @@ class Tree final // NOSONAR cpp:S3624
return NodeType::template search<Pre, Fac>(origin_node_, predicate, factory);
}

/// The function has no effect if the node pointer is `nullptr`, or node is not in the tree (aka unlinked).
/// It is safe to pass the result of search() directly as the `node` argument:
/// `tree.remove(Node<T>::search(root, search_predicate));`
/// The function has no effect if the node pointer is nullptr, or node is not in the tree (aka unlinked).
/// It is safe to pass the result of search() directly as the node argument:
///
/// tree.remove(Node<T>::search(root, search_predicate));
///
/// but it could be done also by direct node removal:
/// ```
///
/// if (auto* const node = Node<T>::search(root, search_predicate) {
/// node->remove();
/// }
/// ```
///
/// Wraps NodeType<>::remove().
///
Expand Down

0 comments on commit 43529b2

Please sign in to comment.