code: func targetToAddr(target string) (*net.TCPAddr, error) {
  	if strings.Contains(target, ":") {
  		// addr host:port passed
  		var err error
  		addr, err := net.ResolveTCPAddr("tcp", target)
  		if err != nil {
  			return nil, fmt.Errorf("couldn't parse dst address: %v", err)
  		}
  		return addr, nil
  	}
  	// try to find port by pid then, connect to local
  	pid, err := strconv.Atoi(target)
  	if err != nil {
  		return nil, fmt.Errorf("couldn't parse PID: %v", err)
  	}
  	port, err := internal.GetPort(pid)
  	if err != nil {
  		return nil, fmt.Errorf("couldn't get port for PID %v: %v", pid, err)
  	}
  	addr, _ := net.ResolveTCPAddr("tcp", "127.0.0.1:"+port)
  	return addr, nil
  }
docs: // targetToAddr tries to parse the target string, be it remote host:port
  // or local process's PID.