Re: Add spaceship assignment operator
| From: | Joe Watkins | Date: | Thu, 24 Mar 2016 18:04:22 +0000 |
| Subject: | Re: Add spaceship assignment operator | ||
| References: | 1 2 | Groups: | php.internals |
| Request: | Send a blank email to internals+get-91912@lists.php.net to get a copy of this message | ||
Morning Nikita,
Thanks for all your hard work.
Since consistency is one of our main focuses, I move that the
discussion period for this extremely important work is moved forward by one
week.
All in favour, say I.
Cheers
Joe
On Thu, Mar 24, 2016 at 5:56 PM, Bob Weinand <bobwei9@hotmail.com> wrote:
>
> > Am 24.3.2016 um 18:50 schrieb Nikita Popov <nikita.ppv@gmail.com>:
> >
> > Hi internals!
> >
> > For consistency, we should add a spaceship assignment operator:
> >
> > $a <=>= $b;
> > // same as
> > $a = ($a <=> $b);
> >
> > Additionally, we should add an is-identical assignment operator:
> >
> > $a ==== $b;
> > // same as
> > $a = ($a === $b);
> >
> > Thank you for taking this proposal under consideration.
> >
> > Regards,
> > Nikita
>
> I see a problem with that … It’d be impossible to make it consistent with
> is-equal comparison…
>
> === is already is-identical comparison. So, no symbol for the is-equal
> assignment operator left.
>
> As long as you don’t have any better suggestion, I’m sorry, but -1 on that.
>
> Bob
>
>
>
>
>