Re: [RFC] Nullsafe operator
| From: | Ryan Jentzsch | Date: | Thu, 04 Jun 2020 11:23:15 +0000 |
| Subject: | Re: [RFC] Nullsafe operator | ||
| References: | 1 | Groups: | php.internals |
| Request: | Send a blank email to internals+get-110366@lists.php.net to get a copy of this message | ||
BIG THUMBS UP for this feature.
As was mentioned that TypeScript uses this and saves developers lots of
time by avoiding nested null checking.
I suggest in the RFC including a list of other languages that have this
feature.
On Tue, Jun 2, 2020, 2:53 PM Ilija Tovilo <tovilo.ilija@gmail.com> wrote:
> Hi internals
>
> I'd like to introduce another RFC I've been working on:
> https://wiki.php.net/rfc/nullsafe_operator
>
> It introduces the nullsafe operator ?-> that skips null values when
> calling functions and fetching properties. In contrast to the last few
> attempts this RFC includes full short circuiting.
>
> Let me know what you think.
>
> Ilija
>
> --
> PHP Internals - PHP Runtime Development Mailing List
> To unsubscribe, visit: http://www.php.net/unsub.php
>
>