code: func (p *protocol) ParsePorts(v buffer.View) (src, dst uint16, err *tcpip.Error) {
  	switch p.number {
  	case ProtocolNumber4:
  		return 0, binary.BigEndian.Uint16(v[header.ICMPv4MinimumSize:]), nil
  	case ProtocolNumber6:
  		return 0, binary.BigEndian.Uint16(v[header.ICMPv6MinimumSize:]), nil
  	}
  	panic(fmt.Sprint("unknown protocol number: ", p.number))
  }
docs: // ParsePorts returns the source and destination ports stored in the given icmp
  // packet.