HH\Lib\OS\inet_ntop

Meta Engineer?

This is available as OS\inet_ntop in the www repository.

Convert an INET or INET6 address to presentation format

namespace HH\Lib\OS;

function inet_ntop(
  AddressFamily $af,
  dynamic $addr,
): string;

See man inet_ntop

Fails with:

  • EAFNOSUPPORT if the address family is not supported
  • EINVAL if the address is the wrong type for the family

Parameters

  • AddressFamily $af
  • dynamic $addr

Returns

  • string