Skip to content

Commit

Permalink
tree_reduce doc: fix formatting
Browse files Browse the repository at this point in the history
  • Loading branch information
rbruenig authored and Philippe-Cholet committed Jun 17, 2024
1 parent 1091f24 commit a0225ce
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -2536,10 +2536,10 @@ pub trait Itertools: Iterator {
///
/// Moreover, the output of `tree_reduce` is preferable to that of [`Iterator::reduce`] in
/// certain cases. For example, building a binary search tree using `tree_reduce` will result in
/// a balanced tree with height O(ln(n)), while [`Iterator::reduce`] will output a tree with
/// height O(n), essentially a linked list.
/// a balanced tree with height `O(ln(n))`, while [`Iterator::reduce`] will output a tree with
/// height `O(n)`, essentially a linked list.
///
/// If 'f' does not benefit from such a reordering, like `u32::wrapping_add`, prefer the
/// If `f` does not benefit from such a reordering, like `u32::wrapping_add`, prefer the
/// normal [`Iterator::reduce`] instead since it will most likely result in the generation of
/// simpler code because the compiler is able to optimize it.
///
Expand Down

0 comments on commit a0225ce

Please sign in to comment.