v1.17.4
Fix typo
This commit is contained in:
+5
-5
@@ -1,7 +1,7 @@
|
||||
package slicesx
|
||||
|
||||
import (
|
||||
`slices`
|
||||
"slices"
|
||||
)
|
||||
|
||||
/*
|
||||
@@ -26,10 +26,10 @@ FirstIndex returns the index of the first element in slice s.
|
||||
|
||||
While at first glance this may seem useless, it may have some usecases as instead of causing panics:
|
||||
|
||||
* If s is empty, idx will be -1.
|
||||
* If s is nil, idx will be -2.
|
||||
* Otherwise idx will ALWAYS be 0.
|
||||
*/_
|
||||
- If s is empty, idx will be -1.
|
||||
- If s is nil, idx will be -2.
|
||||
- Otherwise idx will ALWAYS be 0.
|
||||
*/
|
||||
func FirstIndex[S ~[]E, E any](s S) (idx int) {
|
||||
|
||||
if s == nil {
|
||||
|
||||
Reference in New Issue
Block a user