On 07/04/2025 01:47, Ayesh Karunaratne wrote:
On Mon, Apr 7, 2025 at 2:05 AM Bilge wrote:
... [snip] I suggest first proving there is a
legitimate need.
I did a quick GitHub search for a common pattern of accessing an array
value by using the `array_key_first` and `array_key_last` functions:
`
On Sun, Apr 6, 2025, at 7:47 PM, Ayesh Karunaratne wrote:
>> On Mon, Apr 7, 2025 at 2:05 AM Bilge wrote:
>> ... [snip] I suggest first proving there is a
>> legitimate need.
>
> I did a quick GitHub search for a common pattern of accessing an array
> value by using the `array_key_first` and `array
> On Mon, Apr 7, 2025 at 2:05 AM Bilge wrote:
> ... [snip] I suggest first proving there is a
> legitimate need.
I did a quick GitHub search for a common pattern of accessing an array
value by using the `array_key_first` and `array_key_last` functions:
```php
$value = $arr[array_key_first($resul
On 06/04/2025 18:06, Juris Evertovskis wrote:
I also suspect that an in-engine implementation might have more
performance gains compared to an userland one.
That applies to literally anything, obviously; one less layer of
abstraction is always more efficient. That's therefore not a reason to
On 2025-04-05 18:51, Niels Dossche wrote:
Hi internals
I'm opening the discussion for the RFC "array_first() and
array_last()".
https://wiki.php.net/rfc/array_first_last
Kind regards
Niels
Hi,
Do you think it would be hard or wrong to add `array_nth`? I've had more
trouble with that as th
On Sun, Apr 6, 2025 at 9:52 AM Hans Henrik Bergan
wrote:
> Maybe a
> #[\SuppressUndefinedWarning]
>
> Parameter attribute could work, then everyone could implement their own
> blank() function with their own preferred logic
>
> Not sure if it's technically feasible tho, now the php engine would n