func UnmarshalVarUint64s(dst []uint64, src []byte) ([]byte, error) {
	idx := uint(0)
	for i := range dst {
		if idx >= uint(len(src)) {
			return nil, fmt.Errorf("cannot unmarshal varuint from empty data")
		}
		c := src[idx]
		idx++
		if c < 0x80 {
			// Fast path
			dst[i] = uint64(c)
			continue
		}

		// Slow path
		u := uint64(c & 0x7f)
		startIdx := idx - 1
		shift := uint8(0)
		for c >= 0x80 {
			if idx >= uint(len(src)) {
				return nil, fmt.Errorf("unexpected end of encoded varint at byte %d; src=%x", idx-startIdx, src[startIdx:])
			}
			if idx-startIdx > 9 {
				return src[idx:], fmt.Errorf("too long encoded varint; the maximum allowed length is 10 bytes; got %d bytes; src=%x",
					(idx-startIdx)+1, src[startIdx:])
			}
			c = src[idx]
			idx++
			shift += 7
			u |= uint64(c&0x7f) << shift
		}
		dst[i] = u
	}
	return src[idx:], nil
}
// UnmarshalVarUint64s unmarshals len(dst) uint64 values from src to dst
// and returns the remaining tail from src.
UnmarshalVarUint64s unmarshals len(dst) uint64 values from src to dst
and returns the remaining tail from src.
// UnmarshalVarUint64s unmarshals len ( dst ) uint64 values from src to dst // and returns the remaining tail from src .
func UnmarshalVarUint64s(dst []uint64, src []byte) ([]byte, error) {
	idx := uint(0)
	for i := range dst {
		if idx >= uint(len(src)) {
			return nil, fmt.Errorf("cannot unmarshal varuint from empty data")
		}
		c := src[idx]
		idx++
		if c < 0x80 {
			dst[i] = uint64(c)
			continue
		}
		u := uint64(c & 0x7f)
		startIdx := idx - 1
		shift := uint8(0)
		for c >= 0x80 {
			if idx >= uint(len(src)) {
				return nil, fmt.Errorf("unexpected end of encoded varint at byte %d; src=%x", idx-startIdx, src[startIdx:])
			}
			if idx-startIdx > 9 {
				return src[idx:], fmt.Errorf("too long encoded varint; the maximum allowed length is 10 bytes; got %d bytes; src=%x",
					(idx-startIdx)+1, src[startIdx:])
			}
			c = src[idx]
			idx++
			shift += 7
			u |= uint64(c&0x7f) << shift
		}
		dst[i] = u
	}
	return src[idx:], nil
}
func UnmarshalVarUint64s ( dst [ ] uint64 , src [ ] byte ) ( [ ] byte , error ) { idx := uint ( 0 ) for i := range dst { if idx >= uint ( len ( src ) ) { return nil , fmt . Errorf ( " " ) } c := src [ idx ] idx ++ if c < 0x80 { dst [ i ] = uint64 ( c ) continue } u := uint64 ( c & 0x7f ) startIdx := idx - 1 shift := uint8 ( 0 ) for c >= 0x80 { if idx >= uint ( len ( src ) ) { return nil , fmt . Errorf ( " " , idx - startIdx , src [ startIdx : ] ) } if idx - startIdx > 9 { return src [ idx : ] , fmt . Errorf ( " " , ( idx - startIdx ) + 1 , src [ startIdx : ] ) } c = src [ idx ] idx ++ shift += 7 u |= uint64 ( c & 0x7f ) << shift } dst [ i ] = u } return src [ idx : ] , nil }
UnmarshalVarUint64s unmarshals len(dst) uint64 values from src to dst
and returns the remaining tail from src.
UnmarshalVarUint64s unmarshals len ( dst ) uint64 values from src to dst and returns the remaining tail from src .
// Fast path // Slow path