@@ -779,11 +779,10 @@ impl<T> [T] {
779779 core_slice:: SliceExt :: binary_search_by_key ( self , b, f)
780780 }
781781
782- /// Sorts the slice, in place.
783- ///
784782 /// This is equivalent to `self.sort_by(|a, b| a.cmp(b))`.
785783 ///
786- /// This is a stable sort.
784+ /// This sort is stable and `O(n log n)` worst-case but allocates
785+ /// approximately `2 * n` where `n` is the length of `self`.
787786 ///
788787 /// # Examples
789788 ///
@@ -804,11 +803,9 @@ impl<T> [T] {
804803 /// Sorts the slice, in place, using `key` to extract a key by which to
805804 /// order the sort by.
806805 ///
807- /// This sort is `O(n log n)` worst-case and stable, but allocates
806+ /// This sort is stable and `O(n log n)` worst-case but allocates
808807 /// approximately `2 * n`, where `n` is the length of `self`.
809808 ///
810- /// This is a stable sort.
811- ///
812809 /// # Examples
813810 ///
814811 /// ```rust
@@ -828,7 +825,7 @@ impl<T> [T] {
828825 /// Sorts the slice, in place, using `compare` to compare
829826 /// elements.
830827 ///
831- /// This sort is `O(n log n)` worst-case and stable, but allocates
828+ /// This sort is stable and `O(n log n)` worst-case but allocates
832829 /// approximately `2 * n`, where `n` is the length of `self`.
833830 ///
834831 /// # Examples
0 commit comments