HH\Lib\Vec\concat

Requires the Hack Standard Library to be installed.
Facebook Engineer?

This function is available as Vec\concat() in Facebook's www repository.

Returns a new vec formed by concatenating the given Traversables together

namespace HH\Lib\Vec;

function concat<Tv>(
  Traversable<Tv> $first,
  Container<Tv> ...$rest,
): vec<Tv>;

For a variable number of Traversables, see Vec\flatten().

Time complexity: O(n + m), where n is the size of $first and m is the combined size of all the ...$rest Space complexity: O(n + m), where n is the size of $first and m is the combined size of all the ...$rest

Parameters

Returns

  • vec<Tv>