diff --git a/src/map.rs b/src/map.rs index bd7cd241..4ee24d5f 100644 --- a/src/map.rs +++ b/src/map.rs @@ -796,12 +796,11 @@ where /// Search over a sorted map for a key. /// - /// Returns the position where that key is present, or the position where it can be inserted to maintain the sort. - /// See [`slice::binary_search`] for more details. + /// Returns the position where that key is present, or the position where it can be inserted to + /// maintain the sort. See [`slice::binary_search`] for more details. /// - /// Computes in **O(log(n))** time, - /// which is notably less scalable than looking the key up using [`get_index_of`], - /// but this can also position missing keys. + /// Computes in **O(log(n))** time, which is notably less scalable than looking the key up + /// using [`get_index_of`][IndexMap::get_index_of], but this can also position missing keys. pub fn binary_search_keys(&self, x: &K) -> Result where K: Ord, @@ -811,8 +810,8 @@ where /// Search over a sorted map with a comparator function. /// - /// Returns the position where that value is present, or the position where it can be inserted to maintain the sort. - /// See [`slice::binary_search_by`] for more details. + /// Returns the position where that value is present, or the position where it can be inserted + /// to maintain the sort. See [`slice::binary_search_by`] for more details. /// /// Computes in **O(log(n))** time. #[inline] @@ -825,8 +824,8 @@ where /// Search over a sorted map with an extraction function. /// - /// Returns the position where that value is present, or the position where it can be inserted to maintain the sort. - /// See [`slice::binary_search_by_key`] for more details. + /// Returns the position where that value is present, or the position where it can be inserted + /// to maintain the sort. See [`slice::binary_search_by_key`] for more details. /// /// Computes in **O(log(n))** time. #[inline] diff --git a/src/map/slice.rs b/src/map/slice.rs index 89674469..e2e30961 100644 --- a/src/map/slice.rs +++ b/src/map/slice.rs @@ -204,12 +204,12 @@ impl Slice { /// Search over a sorted map for a key. /// - /// Returns the position where that key is present, or the position where it can be inserted to maintain the sort. - /// See [`slice::binary_search`] for more details. + /// Returns the position where that key is present, or the position where it can be inserted to + /// maintain the sort. See [`slice::binary_search`] for more details. /// - /// Computes in **O(log(n))** time, - /// which is notably less scalable than looking the key up in the map this is a slice from - /// using [`IndexMap::get_index_of`], but this can also position missing keys. + /// Computes in **O(log(n))** time, which is notably less scalable than looking the key up in + /// the map this is a slice from using [`IndexMap::get_index_of`], but this can also position + /// missing keys. pub fn binary_search_keys(&self, x: &K) -> Result where K: Ord, @@ -219,8 +219,8 @@ impl Slice { /// Search over a sorted map with a comparator function. /// - /// Returns the position where that value is present, or the position where it can be inserted to maintain the sort. - /// See [`slice::binary_search_by`] for more details. + /// Returns the position where that value is present, or the position where it can be inserted + /// to maintain the sort. See [`slice::binary_search_by`] for more details. /// /// Computes in **O(log(n))** time. #[inline] @@ -233,8 +233,8 @@ impl Slice { /// Search over a sorted map with an extraction function. /// - /// Returns the position where that value is present, or the position where it can be inserted to maintain the sort. - /// See [`slice::binary_search_by_key`] for more details. + /// Returns the position where that value is present, or the position where it can be inserted + /// to maintain the sort. See [`slice::binary_search_by_key`] for more details. /// /// Computes in **O(log(n))** time. #[inline] diff --git a/src/set.rs b/src/set.rs index a7de3e29..c047b0be 100644 --- a/src/set.rs +++ b/src/set.rs @@ -690,12 +690,11 @@ where /// Search over a sorted set for a value. /// - /// Returns the position where that value is present, or the position where it can be inserted to maintain the sort. - /// See [`slice::binary_search`] for more details. + /// Returns the position where that value is present, or the position where it can be inserted + /// to maintain the sort. See [`slice::binary_search`] for more details. /// - /// Computes in **O(log(n))** time, - /// which is notably less scalable than looking the value up using [`get_index_of`], - /// but this can also position missing values. + /// Computes in **O(log(n))** time, which is notably less scalable than looking the value up + /// using [`get_index_of`][IndexSet::get_index_of], but this can also position missing values. pub fn binary_search(&self, x: &T) -> Result where T: Ord, @@ -705,8 +704,8 @@ where /// Search over a sorted set with a comparator function. /// - /// Returns the position where that value is present, or the position where it can be inserted to maintain the sort. - /// See [`slice::binary_search_by`] for more details. + /// Returns the position where that value is present, or the position where it can be inserted + /// to maintain the sort. See [`slice::binary_search_by`] for more details. /// /// Computes in **O(log(n))** time. #[inline] @@ -719,8 +718,8 @@ where /// Search over a sorted set with an extraction function. /// - /// Returns the position where that value is present, or the position where it can be inserted to maintain the sort. - /// See [`slice::binary_search_by_key`] for more details. + /// Returns the position where that value is present, or the position where it can be inserted + /// to maintain the sort. See [`slice::binary_search_by_key`] for more details. /// /// Computes in **O(log(n))** time. #[inline] diff --git a/src/set/slice.rs b/src/set/slice.rs index 8da4578c..305157a6 100644 --- a/src/set/slice.rs +++ b/src/set/slice.rs @@ -112,12 +112,12 @@ impl Slice { /// Search over a sorted set for a value. /// - /// Returns the position where that value is present, or the position where it can be inserted to maintain the sort. - /// See [`slice::binary_search`] for more details. + /// Returns the position where that value is present, or the position where it can be inserted + /// to maintain the sort. See [`slice::binary_search`] for more details. /// - /// Computes in **O(log(n))** time, - /// which is notably less scalable than looking the value up in the set this is a slice from - /// using [`IndexSet::get_index_of`], but this can also position missing values. + /// Computes in **O(log(n))** time, which is notably less scalable than looking the value up in + /// the set this is a slice from using [`IndexSet::get_index_of`], but this can also position + /// missing values. pub fn binary_search(&self, x: &T) -> Result where T: Ord, @@ -127,8 +127,8 @@ impl Slice { /// Search over a sorted set with a comparator function. /// - /// Returns the position where that value is present, or the position where it can be inserted to maintain the sort. - /// See [`slice::binary_search_by`] for more details. + /// Returns the position where that value is present, or the position where it can be inserted + /// to maintain the sort. See [`slice::binary_search_by`] for more details. /// /// Computes in **O(log(n))** time. #[inline] @@ -141,8 +141,8 @@ impl Slice { /// Search over a sorted set with an extraction function. /// - /// Returns the position where that value is present, or the position where it can be inserted to maintain the sort. - /// See [`slice::binary_search_by_key`] for more details. + /// Returns the position where that value is present, or the position where it can be inserted + /// to maintain the sort. See [`slice::binary_search_by_key`] for more details. /// /// Computes in **O(log(n))** time. #[inline]