Re: RFC [Discussion]: array_find
| From: | Tim Düsterhus | Date: | Sat, 25 May 2024 08:57:34 +0000 |
| Subject: | Re: RFC [Discussion]: array_find | ||
| References: | 1 2 | Groups: | php.internals |
| Request: | Send a blank email to internals+get-123428@lists.php.net to get a copy of this message | ||
Hi
On 5/25/24 01:19, Valentin Udaltsov wrote:
Have you considered renamingFor an entirely new API I would agree. But for the array_* functions we already have $callback for array_filter (and also array_map and array_reduce, but those are not predicate callbacks). Also given the vote started with the $callback name and the fact that parameter names are part of the API (due to named parameters), it's probably to late to change it. Best regards Tim Düsterhus$callbackparameter to$predicate? I always considered "callback" to be a very generic word. Predicate, on the contrary, implies accepting a value and returning a bool.