HH\Lib\C\firstx_async

Meta Engineer?

This is available as C\firstx_async in the www repository.

Deprecated: use C\firstx(await #A)

Returns the first element of the result of the given Awaitable, or throws if the Traversable is empty

namespace HH\Lib\C;

function firstx_async<T>(
  Awaitable<Traversable<T>> $awaitable,
): Awaitable<T>;

For non-Awaitable Traversables, see C\firstx.

Time complexity: O(1) Space complexity: O(1)

Parameters

Returns