Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:98144 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 85146 invoked from network); 3 Feb 2017 20:36:25 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 3 Feb 2017 20:36:25 -0000 Authentication-Results: pb1.pair.com header.from=ilija.tovilo@me.com; sender-id=pass Authentication-Results: pb1.pair.com smtp.mail=ilija.tovilo@me.com; spf=pass; sender-id=pass Received-SPF: pass (pb1.pair.com: domain me.com designates 17.172.80.96 as permitted sender) X-PHP-List-Original-Sender: ilija.tovilo@me.com X-Host-Fingerprint: 17.172.80.96 st11p00im-asmtp002.me.com Received: from [17.172.80.96] ([17.172.80.96:48474] helo=st11p00im-asmtp002.me.com) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id C9/96-38491-7C9E4985 for ; Fri, 03 Feb 2017 15:36:23 -0500 Received: from process-dkim-sign-daemon.st11p00im-asmtp002.me.com by st11p00im-asmtp002.me.com (Oracle Communications Messaging Server 7.0.5.38.0 64bit (built Feb 26 2016)) id <0OKT00E00FVN3K00@st11p00im-asmtp002.me.com> for internals@lists.php.net; Fri, 03 Feb 2017 20:36:20 +0000 (GMT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=me.com; s=4d515a; t=1486154180; bh=SAmOrlIF+xaoicvSUwtKq+LwaFyePVV4yM/JPl8FW/Y=; h=Date:From:To:Message-id:Subject:MIME-version:Content-type; b=aICXncQBH8giI9wTe5ltkZwdDxd7yzNEa5vNxZyafI8kBkKUgFZWAGGpT42R2YBAT f9LsxTQAs6DKkuHACUhOZw/OG1znNvFMFdqUpmTRSJeBZsIYCegB+347YtFy3jZTqY ATU+IgmaW9m6y5LUvvUT7bkpyBz5I1KJXpKrf4bv2pCqWkilEeXubzr9E5qqbpYtKK VIemxtsGMMyjTtYH6KSTLU9lO4ewHkU0l3gWF9Mc5FhMVzkAQ2G0euEsF7Q8A84w7r mv5+2R4RwbdLLBLMyio+NIIKNVTgcpoi863rdbgV9GPJwa5Jec3K4kfHXnJqsSrxmq lSSIR9tzRA4Zw== Received: from icloud.com ([127.0.0.1]) by st11p00im-asmtp002.me.com (Oracle Communications Messaging Server 7.0.5.38.0 64bit (built Feb 26 2016)) with ESMTPSA id <0OKT00H9KFWHF330@st11p00im-asmtp002.me.com>; Fri, 03 Feb 2017 20:36:19 +0000 (GMT) X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10432:,, definitions=2017-02-03_13:,, signatures=0 X-Proofpoint-Spam-Details: rule=notspam policy=default score=0 spamscore=0 clxscore=1034 suspectscore=74 malwarescore=0 phishscore=0 adultscore=0 bulkscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.0.1-1603290000 definitions=main-1702030193 Date: Fri, 03 Feb 2017 21:34:43 +0100 To: Andrea Faulds , Levi Morrison Cc: internals Message-ID: <611b72db-420f-4963-ab92-0ddf977a0aaa@Spark> In-reply-to: References: <19.45.38491.677D4985@pb1.pair.com> X-Readdle-Message-ID: 611b72db-420f-4963-ab92-0ddf977a0aaa@Spark MIME-version: 1.0 Content-type: multipart/alternative; boundary=5894e9bf_6b8b4567_4609 Subject: Re: [PHP-DEV] Re: [RFC][Discuss] Arrow Functions From: ilija.tovilo@me.com --5894e9bf_6b8b4567_4609 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Content-Disposition: inline I like the suggested syntax. The only drawback I see is that it inhibits = the future addition of union types for closures: =C2=A0 =C2=A0 =7Cint =7C float =24x=7C =3D> =24x Adding parentheses of course resolves the issue but looks a bit awkward: =C2=A0 =C2=A0 =7C(int =7C float) =24x=7C =3D> =24x Apart from that I have nothing to complain about. I'd be happy either way= . On 3 =46eb 2017, 21:24 +0100, Levi Morrison , wrote: > On =46ri, =46eb 3, 2017 at 12:18 PM, Andrea =46aulds wro= te: > > Hi David, > > > > David Rodrigues wrote: > > > > > > Hello folks=21 > > > I just not understand why =22function=22 should be abbreviated. It'= s about > > > =22how > > > less character better=22=3F I don't see it too much on PHP. I guess= that is > > > more simple keep what exists current =22function=22, that all knows= about > > > (that > > > should be better than the next example): > > > > > > =24mapped =3D array=5Fmap(function(=24x) =3D> =24x + =24y); // vs c= urrent: > > > =24mapped =3D array=5Fmap(function(=24x) use(=24y) =7B return =24x = + =24y =7D); > > > > > > I feel the same way. It would be nice to have shorter syntax, but it > > sacrifices readability and familiarity here, and adds yet another new= > > keyword. > > > > It also feels inconsistent=E2=80=A6 isn't =22fn=22 just short for =22= function=22=3F Why is it > > exclusive to the =3D> syntax=3F > > This is not exactly on topic... unless you are implying you'd prefer > the =60=7C=24x=7C =3D> =24x + =24y=60=3F Maybe you missed =5Bthis=5D=5B= 1=5D message=3F > > =5B1=5D: http://news.php.net/php.internals/98136 > > -- > PHP Internals - PHP Runtime Development Mailing List > To unsubscribe, visit: http://www.php.net/unsub.php > --5894e9bf_6b8b4567_4609--