We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 11b54cc commit b0443e0Copy full SHA for b0443e0
src/lib.rs
@@ -2289,7 +2289,8 @@ pub trait Itertools : Iterator {
2289
/// Sort the k smallest elements into a new iterator, in ascending order.
2290
///
2291
/// **Note:** This consumes the entire iterator, and returns the result
2292
- /// as a new iterator that owns its elements.
+ /// as a new iterator that owns its elements. If the input contains
2293
+ /// less than k elements, the result is equivalent to `self.sorted()`.
2294
2295
/// This is guaranteed to use `k * sizeof(Self::Item) + O(1)` memory
2296
/// and `O(n log k)` time, with `n` the number of elements in the input.
0 commit comments