Re: [PHP-DEV] [RFC] Implicit isset() in Shorthand Ternary Operator

[email protected] (Andrea Faulds)
Newsgroups php.internals
Message-ID <[email protected]>
On 10 Sep 2014, at 10:31, Pierre Joye <[email protected]> wrote:

> On Tue, Sep 9, 2014 at 12:58 AM, Adam Harvey <[email protected]> wrote:
>> On 8 September 2014 07:56, Christoph Becker <[email protected]> wrote:
>> +1 on ?? — there's precedent for it, and it means we don't have to
>> explain why the shorthand form of an operator behaves differently to
>> the long form, which is just going to confuse users.
> 
> After a 2nd look I have to agree here too. Changing behavior in
> something so widely used as the current operator will likely create
> more pains. A new operator, clearly documented, sounds much cleaner,
> even more as it does something different anyway.

By popular demand, I’ve changed the RFC to instead propose a ?? operator, after Nikita Popov generously donated a working ?? patch. In doing so, the RFC is renamed “Null Coalesce Operator”.

Please read it: https://wiki.php.net/rfc/isset_ternary

Thanks!
--
Andrea Faulds
http://ajf.me/
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.