# [RFC] [Vote] array_first() and array_last()

- Thread: https://externals.io/message/127171
- Original archive: https://news-web.php.net/php.internals/127171
- Started by Niels Dossche on 2025-04-22T20:52:04+00:00
- Messages: 3
- RFC: array_first() and array_last() (Implemented (PHP 8.5)) — https://externals.io/rfc/array_first_last.md
- Reply by email to internals@lists.php.net
- More for agents: search with https://externals.io/search.md?q={query} · RFCs at https://externals.io/rfc.md · JSON API at https://externals.io/api · documentation at https://externals.io/llms.txt

---

## #127171 — Niels Dossche — 2025-04-22T20:52:04+00:00

URL: https://externals.io/message/127171#127171

Hi internals

I'm opening the vote for https://wiki.php.net/rfc/array_first_last
Vote runs until 2025-05-06 23:59:59 CEST.

Kind regards
Niels

---

## #127177 — Levi Morrison — 2025-04-23T20:44:03+00:00

URL: https://externals.io/message/127171#127177 · In reply to: #127171

>
> Hi internals
>
> I'm opening the vote for https://wiki.php.net/rfc/array_first_last
> Vote runs until 2025-05-06 23:59:59 CEST.
>
> Kind regards
> Niels

I've voted yes. I still don't like functions which conflate null as an
error and null as a legitimate value. I think that the user can
reasonably avoid this edge in many cases, and we don't really have a
better option (ha) than throwing an exception, which doesn't seem
right to me in this case.

So it's a reluctant yes.

---

## #127298 — Niels Dossche — 2025-05-07T06:17:55+00:00

URL: https://externals.io/message/127171#127298 · In reply to: #127171

> Hi internals
> 
> I'm opening the vote for https://wiki.php.net/rfc/array_first_last
> Vote runs until 2025-05-06 23:59:59 CEST.
> 
> Kind regards
> Niels
> 

Hi internals

Vote ended with 35 yes, 0 no.
Thanks to all participants.
Merged into master.

Kind regards
Niels
