芝麻web文件管理V1.00
编辑当前文件:/home/qrafawbu/qrafiqxcreativeagency.com/accounts/office/vendor/azjezz/psl/src/Psl/Dict/flip.php
1, 'b' => 2, 'c' => 3]) * => Dict(1 => 'a', 2 => 'b', 3 => 'c') * * @template Tk of array-key * @template Tv of array-key * * @param iterable
$iterable * * @return array
*/ function flip(iterable $iterable): array { $result = []; foreach ($iterable as $key => $value) { Psl\invariant( Type\array_key()->matches($value), 'Expected all values to be of type array-key, value of type (%s) provided.', gettype($value) ); /** @var Tv $value */ $result[$value] = $key; } return $result; }