diff --git a/src/iterable-functions.php b/src/iterable-functions.php index 0b03386..95c4b50 100644 --- a/src/iterable-functions.php +++ b/src/iterable-functions.php @@ -70,9 +70,14 @@ function iterable_to_traversable(iterable $iterable): Traversable /** * Filters an iterable. * - * @param iterable $iterable + * @param (callable(TValue):bool)|null $filter * - * @return iterable + * @psalm-param iterable $iterable + * @phpstan-param iterable $iterable https://github.com/phpstan/phpstan/issues/4498 + * @psalm-return iterable + * @phpstan-return iterable https://github.com/phpstan/phpstan/issues/4498 + * @template TKey + * @template TValue */ function iterable_filter(iterable $iterable, ?callable $filter = null): iterable {