Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:80823 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 78044 invoked from network); 19 Jan 2015 14:34:02 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 19 Jan 2015 14:34:02 -0000 Authentication-Results: pb1.pair.com smtp.mail=ajf@ajf.me; spf=pass; sender-id=pass Authentication-Results: pb1.pair.com header.from=ajf@ajf.me; sender-id=pass Received-SPF: pass (pb1.pair.com: domain ajf.me designates 192.64.116.207 as permitted sender) X-PHP-List-Original-Sender: ajf@ajf.me X-Host-Fingerprint: 192.64.116.207 imap2-2.ox.privateemail.com Received: from [192.64.116.207] ([192.64.116.207:33371] helo=imap2-2.ox.privateemail.com) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id 0D/94-64889-2211DB45 for ; Mon, 19 Jan 2015 09:13:58 -0500 Received: from localhost (localhost [127.0.0.1]) by mail.privateemail.com (Postfix) with ESMTP id 581788C0083; Mon, 19 Jan 2015 09:13:51 -0500 (EST) X-Virus-Scanned: Debian amavisd-new at imap2.ox.privateemail.com Received: from mail.privateemail.com ([127.0.0.1]) by localhost (imap2.ox.privateemail.com [127.0.0.1]) (amavisd-new, port 10024) with LMTP id wp8DGPTAsW8J; Mon, 19 Jan 2015 09:13:51 -0500 (EST) Received: from oa-res-26-240.wireless.abdn.ac.uk (oa-res-26-240.wireless.abdn.ac.uk [137.50.26.240]) (using TLSv1 with cipher ECDHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by mail.privateemail.com (Postfix) with ESMTPSA id 782D78C0080; Mon, 19 Jan 2015 09:13:50 -0500 (EST) Content-Type: text/plain; charset=utf-8 Mime-Version: 1.0 (Mac OS X Mail 8.1 \(1993\)) In-Reply-To: <20150119125315.GT7486@phcomp.co.uk> Date: Mon, 19 Jan 2015 14:13:47 +0000 Cc: internals@lists.php.net Content-Transfer-Encoding: quoted-printable Message-ID: References: <53F8A1FF-C809-4DDF-9C6F-6916C3E4F044@ajf.me> <20150119110639.GO7486@phcomp.co.uk> <8A3DA508-E6A3-486C-8A84-839AEC78D0FF@ajf.me> <20150119125315.GT7486@phcomp.co.uk> To: Alain Williams X-Mailer: Apple Mail (2.1993) Subject: Re: [PHP-DEV] [RFC] Combined Comparison (Spaceship) Operator From: ajf@ajf.me (Andrea Faulds) Hi Alain, > On 19 Jan 2015, at 12:53, Alain Williams wrote: >=20 > On Mon, Jan 19, 2015 at 12:30:14PM +0000, Andrea Faulds wrote: >>=20 >>=20 >>> On 19 Jan 2015, at 11:06, Alain Williams wrote: >>>=20 >>> I like it. >>>=20 >>> The RFC does not say what the precedence is to be. Could I suggest = that it be >>> the same as ''=3D=3D !=3D =3D=3D=3D !=3D=3D <>'' - which keeps it = consistent with Perl. >>=20 >> It has the same precedence as the other comparison operators, it=E2=80=99= s non-associative. >=20 > Sorry to be a persistent pain, but PHP has 2 sets of comparison = operators with > different precedence: >=20 > ''< <=3D > >=3D'' >=20 > ''=3D=3D !=3D =3D=3D=3D !=3D=3D <>'' >=20 > I think that the RFC should clearly state that spaceship joins the 2nd = set of > operators in the precedence table. The introduction kind of hints that = it would > join the first lot -- but that would be inconsistent with Perl. >=20 > http://uk1.php.net/manual/en/language.operators.precedence.php Ah, I get you. I=E2=80=99m making it the same precedence as Perl (same = as =3D=3D and !=3D), then. I=E2=80=99ve updated the RFC and will update = the patch. Thanks. -- Andrea Faulds http://ajf.me/