1
0
mirror of https://github.com/golang/go synced 2024-11-15 08:50:40 -07:00
go/src/slices
Matt Layher f6c3a3e3c8 slices: add Chunk
Chunk returns an iterator over consecutive sub-slices of up to n elements of s.

Fixes #53987.

Change-Id: I508274eca388db39550eb9e4d8abd5ce68d29d8d
Reviewed-on: https://go-review.googlesource.com/c/go/+/562935
Reviewed-by: Cherry Mui <cherryyz@google.com>
LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com>
Reviewed-by: Ian Lance Taylor <iant@google.com>
Auto-Submit: Ian Lance Taylor <iant@google.com>
2024-05-10 17:28:50 +00:00
..
example_test.go slices: add Chunk 2024-05-10 17:28:50 +00:00
iter_test.go slices: add Chunk 2024-05-10 17:28:50 +00:00
iter.go slices: add Chunk 2024-05-10 17:28:50 +00:00
slices_test.go slices: optimize Compact and CompactFunc 2024-04-26 13:32:06 +00:00
slices.go slices: reduce code nesting depth for Compact and CompactFunc 2024-04-29 14:01:59 +00:00
sort_benchmark_test.go strings: intrinsify and optimize Compare 2024-04-04 23:39:07 +00:00
sort_test.go slices: add iterator-related functions 2024-05-09 19:20:55 +00:00
sort.go
zsortanyfunc.go
zsortordered.go