@@ -948,7 +948,7 @@ pub trait Itertools : Iterator {
948
948
}
949
949
950
950
/// Return an iterator adaptor that merges the two base iterators in order.
951
- /// This is much like `.merge()` but allows for a custom ordering.
951
+ /// This is much like [ `.merge()`](Itertools::merge) but allows for a custom ordering.
952
952
///
953
953
/// This can be especially useful for sequences of tuples.
954
954
///
@@ -1935,7 +1935,7 @@ pub trait Itertools : Iterator {
1935
1935
concat ( self )
1936
1936
}
1937
1937
1938
- /// `.collect_vec()` is simply a type specialization of `. collect()` ,
1938
+ /// `.collect_vec()` is simply a type specialization of [`Iterator:: collect`] ,
1939
1939
/// for convenience.
1940
1940
#[ cfg( feature = "use_alloc" ) ]
1941
1941
fn collect_vec ( self ) -> Vec < Self :: Item >
@@ -2057,7 +2057,7 @@ pub trait Itertools : Iterator {
2057
2057
2058
2058
/// Format all iterator elements, separated by `sep`.
2059
2059
///
2060
- /// This is a customizable version of `.format()`.
2060
+ /// This is a customizable version of [ `.format()`](Itertools::format) .
2061
2061
///
2062
2062
/// The supplied closure `format` is called once per iterator element,
2063
2063
/// with two arguments: the element and a callback that takes a
@@ -2164,7 +2164,7 @@ pub trait Itertools : Iterator {
2164
2164
/// value is returned inside `Some`. Otherwise, the operation terminates
2165
2165
/// and returns `None`. No iterator elements are consumed after the `None`.
2166
2166
///
2167
- /// This is the `Option` equivalent to `fold_ok`.
2167
+ /// This is the `Option` equivalent to [ `fold_ok`](Itertools::fold_ok) .
2168
2168
///
2169
2169
/// ```
2170
2170
/// use std::ops::Add;
@@ -2318,7 +2318,7 @@ pub trait Itertools : Iterator {
2318
2318
2319
2319
/// An iterator method that applies a function, producing a single, final value.
2320
2320
///
2321
- /// `fold_while()` is basically equivalent to ` fold()` but with additional support for
2321
+ /// `fold_while()` is basically equivalent to [`Iterator:: fold`] but with additional support for
2322
2322
/// early exit via short-circuiting.
2323
2323
///
2324
2324
/// ```
@@ -2437,7 +2437,7 @@ pub trait Itertools : Iterator {
2437
2437
/// Sort all iterator elements into a new iterator in ascending order.
2438
2438
///
2439
2439
/// **Note:** This consumes the entire iterator, uses the
2440
- /// `slice::sort_unstable()` method and returns the result as a new
2440
+ /// [ `slice::sort_unstable`] method and returns the result as a new
2441
2441
/// iterator that owns its elements.
2442
2442
///
2443
2443
/// The sorted iterator, if directly collected to a `Vec`, is converted
@@ -2466,7 +2466,7 @@ pub trait Itertools : Iterator {
2466
2466
/// Sort all iterator elements into a new iterator in ascending order.
2467
2467
///
2468
2468
/// **Note:** This consumes the entire iterator, uses the
2469
- /// `slice::sort_unstable_by()` method and returns the result as a new
2469
+ /// [ `slice::sort_unstable_by`] method and returns the result as a new
2470
2470
/// iterator that owns its elements.
2471
2471
///
2472
2472
/// The sorted iterator, if directly collected to a `Vec`, is converted
@@ -2499,7 +2499,7 @@ pub trait Itertools : Iterator {
2499
2499
/// Sort all iterator elements into a new iterator in ascending order.
2500
2500
///
2501
2501
/// **Note:** This consumes the entire iterator, uses the
2502
- /// `slice::sort_unstable_by_key()` method and returns the result as a new
2502
+ /// [ `slice::sort_unstable_by_key`] method and returns the result as a new
2503
2503
/// iterator that owns its elements.
2504
2504
///
2505
2505
/// The sorted iterator, if directly collected to a `Vec`, is converted
@@ -2533,7 +2533,7 @@ pub trait Itertools : Iterator {
2533
2533
/// Sort all iterator elements into a new iterator in ascending order.
2534
2534
///
2535
2535
/// **Note:** This consumes the entire iterator, uses the
2536
- /// `slice::sort()` method and returns the result as a new
2536
+ /// [ `slice::sort`] method and returns the result as a new
2537
2537
/// iterator that owns its elements.
2538
2538
///
2539
2539
/// The sorted iterator, if directly collected to a `Vec`, is converted
@@ -2562,7 +2562,7 @@ pub trait Itertools : Iterator {
2562
2562
/// Sort all iterator elements into a new iterator in ascending order.
2563
2563
///
2564
2564
/// **Note:** This consumes the entire iterator, uses the
2565
- /// `slice::sort_by()` method and returns the result as a new
2565
+ /// [ `slice::sort_by`] method and returns the result as a new
2566
2566
/// iterator that owns its elements.
2567
2567
///
2568
2568
/// The sorted iterator, if directly collected to a `Vec`, is converted
@@ -2595,7 +2595,7 @@ pub trait Itertools : Iterator {
2595
2595
/// Sort all iterator elements into a new iterator in ascending order.
2596
2596
///
2597
2597
/// **Note:** This consumes the entire iterator, uses the
2598
- /// `slice::sort_by_key()` method and returns the result as a new
2598
+ /// [ `slice::sort_by_key`] method and returns the result as a new
2599
2599
/// iterator that owns its elements.
2600
2600
///
2601
2601
/// The sorted iterator, if directly collected to a `Vec`, is converted
@@ -2664,7 +2664,7 @@ pub trait Itertools : Iterator {
2664
2664
}
2665
2665
2666
2666
/// Collect all iterator elements into one of two
2667
- /// partitions. Unlike `Iterator::partition`, each partition may
2667
+ /// partitions. Unlike [ `Iterator::partition`] , each partition may
2668
2668
/// have a distinct type.
2669
2669
///
2670
2670
/// ```
@@ -2865,11 +2865,11 @@ pub trait Itertools : Iterator {
2865
2865
/// Return the minimum and maximum element of an iterator, as determined by
2866
2866
/// the specified function.
2867
2867
///
2868
- /// The return value is a variant of [`MinMaxResult`] like for ` minmax()`.
2868
+ /// The return value is a variant of [`MinMaxResult`] like for [`. minmax()`](Itertools::minmax) .
2869
2869
///
2870
2870
/// For the minimum, the first minimal element is returned. For the maximum,
2871
2871
/// the last maximal element wins. This matches the behavior of the standard
2872
- /// `Iterator::min()` and `Iterator::max()` methods.
2872
+ /// [ `Iterator::min`] and [ `Iterator::max`] methods.
2873
2873
///
2874
2874
/// The keys can be floats but no particular result is guaranteed
2875
2875
/// if a key is NaN.
@@ -2882,11 +2882,11 @@ pub trait Itertools : Iterator {
2882
2882
/// Return the minimum and maximum element of an iterator, as determined by
2883
2883
/// the specified comparison function.
2884
2884
///
2885
- /// The return value is a variant of [`MinMaxResult`] like for ` minmax()`.
2885
+ /// The return value is a variant of [`MinMaxResult`] like for [`. minmax()`](Itertools::minmax) .
2886
2886
///
2887
2887
/// For the minimum, the first minimal element is returned. For the maximum,
2888
2888
/// the last maximal element wins. This matches the behavior of the standard
2889
- /// `Iterator::min()` and `Iterator::max()` methods.
2889
+ /// [ `Iterator::min`] and [ `Iterator::max`] methods.
2890
2890
fn minmax_by < F > ( self , mut compare : F ) -> MinMaxResult < Self :: Item >
2891
2891
where Self : Sized , F : FnMut ( & Self :: Item , & Self :: Item ) -> Ordering
2892
2892
{
0 commit comments