isEqualTo. Bind a value; the returned Closure returns true for anything that isn't it (loosely).
Creates a predicate Closure that is true when the passed value is loosely NOT equal (!=) to the bound value.
/**
* @param mixed $a
* @return Closure(mixed):bool
*/
Comparisons\isNotEqualTo($a): ClosureWhen Comparisons\isNotEqualTo() is called, it returns the following Closure which can be used like a regular function.
/**
* @param mixed $b
* @return bool
*/
$function ($b): boolThis can be used to create a simple closure which can be used as a regular function.
$notFoo = Comparisons\isNotEqualTo('foo');
$withoutFoo = array_filter(['foo', 'bar', 'foo', 'baz'], $notFoo);
print_r($withoutFoo); // ['bar', 'baz']