modernizes for loop in cmd/, internal/ (#21309)

This commit is contained in:
ILIYA
2025-05-28 00:19:03 +09:00
committed by GitHub
parent ea77bcfc98
commit 0a36d41dcd
27 changed files with 44 additions and 44 deletions

View File

@@ -846,7 +846,7 @@ func decodeXLHeaders(buf []byte) (versions int, headerV, metaV uint8, b []byte,
// Any non-nil error is returned.
func decodeVersions(buf []byte, versions int, fn func(idx int, hdr, meta []byte) error) (err error) {
var tHdr, tMeta []byte // Zero copy bytes
for i := 0; i < versions; i++ {
for i := range versions {
tHdr, buf, err = msgp.ReadBytesZC(buf)
if err != nil {
return err