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 3bcf042 commit 39d4317Copy full SHA for 39d4317
slices/slices.go
@@ -5,6 +5,11 @@
5
// Package slices defines various functions useful with slices of any type.
6
// Unless otherwise specified, these functions all apply to the elements
7
// of a slice at index 0 <= i < len(s).
8
+//
9
+// Note that the less function in IsSortedFunc, SortFunc, SortStableFunc requires a
10
+// strict weak ordering (https://en.wikipedia.org/wiki/Weak_ordering#Strict_weak_orderings),
11
+// or the sorting may fail to sort correctly. A common case is when sorting slices of
12
+// floating-point numbers containing NaN values.
13
package slices
14
15
import "golang.org/x/exp/constraints"
0 commit comments