Re: [RFC] anti-coalescing-operator

From: Date: Fri, 25 Oct 2019 00:03:21 +0000
Subject: Re: [RFC] anti-coalescing-operator
References: 1 2 3 4  Groups: php.internals 
Request: Send a blank email to internals+get-107683@lists.php.net to get a copy of this message
On Fri, 25 Oct 2019 at 01:28, Sara Golemon <pollita@php.net> wrote: > > On Thu, Oct 24, 2019 at 12:46 PM Stephen Reay <php-lists@koalephant.com> > wrote: > > > This sounds like an alternative approach (for solving the same basic > > problem) to the nullsafe operator discussed a while back, no? > > https://wiki.php.net/rfc/nullsafe_calls > > > > At the risk of hijacking, @matthewrask asked me about ?-> a couple weeks > ago (Javascript is making this one popular), and I threw together a rough > PoC at > > https://github.com/php/php-src/compare/master...sgolemon:null-coalesce > which > I suspect he intends to RFC properly soon. As long as the topic is at > hand, what's the general appetite for it? Should I bother polishing the > turd? > > -Sara ?-> is a great idea. The problem is this only works for method chaining, not for function argument nesting. So we might want something else in addition to that. foo(bar(baz() ???) ???); -- Andreas

« previous php.internals (#107683) next »