Skip to content

Commit 06b17a2

Browse files
authored
Clarify that ordering is unspecified
1 parent b9f008b commit 06b17a2

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

library/alloc/src/slice.rs

+2
Original file line numberDiff line numberDiff line change
@@ -373,6 +373,8 @@ impl<T> [T] {
373373
///
374374
/// During sorting, the key function is called at most once per element, by using
375375
/// temporary storage to remember the results of key evaluation.
376+
/// The order of calls to the key function is unspecified and may change in future versions
377+
/// of the standard library.
376378
///
377379
/// This sort is stable (i.e., does not reorder equal elements) and *O*(*m* \* *n* + *n* \* log(*n*))
378380
/// worst-case, where the key function is *O*(*m*).

0 commit comments

Comments
 (0)