Le lundi 11 février 2019, 08:59:17 CET Levi Morrison a écrit : > My position is the same: pushing the variadic behavior into the > functions means that each function needs to pick `||` or `&&` > behavior, both of which are useful. I would rather see more > descriptive function names, such as `all_of` or `any_of`: > > if (!all_of('is_numeric', [$input['example1'], > $input['example2']])) {/*...*/}
My first thought was that this must already exists under another name, but it seems that none of array_map, array_walk or array_reduce allows to do that easily. (That is, in a more readable way than the boolean operator string, otherwise it’s useless) Côme -- PHP Internals - PHP Runtime Development Mailing List To unsubscribe, visit: http://www.php.net/unsub.php