code: func hasDups(zm []zipMetaInfo) bool {
  	i := 0
  	var dataSize uint32
  	var firstDup blob.Ref
  	dupFound := false
  	for _, z := range zm {
  		if z.wholePartIndex == i {
  			firstDup = z.zipRef
  			dataSize = z.dataSize
  			i++
  			continue
  		}
  		// we could return true right now, but we want to go through it all, to make
  		// sure our assumption that "same part index -> duplicate" is true, using at least
  		// the dataSize to confirm. For a better effort, we should use DataBlobsOrigin.
  		if z.dataSize != dataSize {
  			panic(fmt.Sprintf("%v and %v looked like duplicates at first, but don't actually have the same dataSize. TODO: add DataBlobsOrigin checking.", firstDup, z.zipRef))
  		}
  		dupFound = true
  	}
  	return dupFound
  }
docs: // hasDups reports whether zm contains successive zipRefs which have the same
  // wholePartIndex, which we assume means they have the same data contents. It
  // panics if that assumption seems wrong, i.e. if the data within assumed
  // duplicates is not the same size in all of them. zm must be sorted by
  // wholePartIndex.
  // See https://github.com/perkeep/perkeep/issues/1079