HH\Lib\Dict\partition_with_key

This API is part of the Hack Standard Library, not HHVM itself.
Facebook Engineer?

This function is available as Dict\partition_with_key() in Facebook's www repository.

Returns a 2-tuple containing dicts for which the given keyed predicate returned true and false, respectively

Description

namespace HH\Lib\Dict;

function partition_with_key<Tk as arraykey, Tv>(
  KeyedTraversable<Tk, Tv> $traversable,
  (function(Tk,Tv):bool) $predicate,
): (dict<Tk,Tv>,dict<Tk,Tv>);

Parameters