Re: Any interest in a list type?
| From: | Levi Morrison via internals | Date: | Thu, 23 Apr 2020 05:33:14 +0000 |
| Subject: | Re: Any interest in a list type? | ||
| References: | 1 2 3 4 5 6 7 | Groups: | php.internals |
| Request: | Send a blank email to internals+get-109799@lists.php.net to get a copy of this message | ||
On Wed, Apr 22, 2020 at 11:03 PM Matthew Brown <matthewmatthew@gmail.com> wrote:
>
> > This is the *design* process for a language, and it's important...
> Stepping back to reconsider how collections work generally, and how we can
> improve them in a graceful way that leads to a clean end-state, would be
> very valuable.
>
> Though you have much more experience with internals than I do, I think that
> building a consensus around a bold new vision for PHP collections would be
> a near-Sisyphean task.
>
> Adding a list/vector type would be a much smaller, more easily definable
> task – it was one of the first new types that Hack added, and by all
> accounts they're pretty happy with that decision.
IIRC, they switched from object semantics to value semantics (like PHP
arrays). Can someone more knowledgeable confirm?
>
> > Should we also be adding a dedicated dictionary type as well?
>
> Maybe? I think there'd be less to gain from a performance standpoint
> though, so I didn't want to lump that in with any list proposal and risk
> derailment.