code: func (r *Record) End() int {
  	if r.Flags&Unmapped != 0 || len(r.Cigar) == 0 {
  		return r.Pos + 1
  	}
  	pos := r.Pos
  	end := pos
  	for _, co := range r.Cigar {
  		pos += co.Len() * co.Type().Consumes().Reference
  		end = max(end, pos)
  	}
  	return end
  }
docs: // End returns the highest query-consuming coordinate end of the alignment.
  // The position returned by End is not valid if r.Cigar.IsValid(r.Seq.Length)
  // is false.