Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:98077 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 95722 invoked from network); 31 Jan 2017 12:38:48 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 31 Jan 2017 12:38:48 -0000 Authentication-Results: pb1.pair.com smtp.mail=me@kelunik.com; spf=permerror; sender-id=unknown Authentication-Results: pb1.pair.com header.from=me@kelunik.com; sender-id=unknown Received-SPF: error (pb1.pair.com: domain kelunik.com from 81.169.146.216 cause and error) X-PHP-List-Original-Sender: me@kelunik.com X-Host-Fingerprint: 81.169.146.216 mo4-p00-ob.smtp.rzone.de Received: from [81.169.146.216] ([81.169.146.216:29387] helo=mo4-p00-ob.smtp.rzone.de) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id DA/F4-51557-75580985 for ; Tue, 31 Jan 2017 07:38:48 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; t=1485866325; l=3726; s=domk; d=kelunik.com; h=Content-Type:To:Subject:Date:From:In-Reply-To:References: MIME-Version; bh=+DkC/oXW3IY/SR8WRyX+v0k9xA9OiBHhxUaDul+iSOI=; b=U5PK+kbYXaqvHigCC30/vx0C/SyS43RMhlluzSRsC8feaqWS8EKuofMmyqUm6OiLM2 7T1zAl1gGdfFHdZKqoefZ16ToMqhrJMZ7bSJ+faxcf0dWHCOm+BiBj54SIBQXzDBmATi xJxrjG61nu9wrZbl4cHrAI5fehwBYBHnSLIf4= X-RZG-AUTH: :IWkkfkWkbvHsXQGmRYmUo9mls2vWuiu+7SLDup6E67mzuoNJBqD/si4= X-RZG-CLASS-ID: mo00 Received: from mail-qt0-f172.google.com ([209.85.216.172]) by smtp.strato.de (RZmta 39.12 AUTH) with ESMTPSA id z0b3dbt0VCciCNd (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (curve secp384r1 with 384 ECDH bits, eq. 7680 bits RSA)) (Client did not present a certificate) for ; Tue, 31 Jan 2017 13:38:44 +0100 (CET) Received: by mail-qt0-f172.google.com with SMTP id v23so231734264qtb.0 for ; Tue, 31 Jan 2017 04:38:44 -0800 (PST) X-Gm-Message-State: AIkVDXL7M4NUDTxrCyMGS3OhdfUJMjSXEMDgPPQoNq6wr4KPEKhoAt0CJizDDEQY6cwGIfbiYH/2Kyuq8YO7lg== X-Received: by 10.200.2.8 with SMTP id k8mr23810532qtg.163.1485866324193; Tue, 31 Jan 2017 04:38:44 -0800 (PST) MIME-Version: 1.0 References: <20170131122056.GA14569@phcomp.co.uk> In-Reply-To: <20170131122056.GA14569@phcomp.co.uk> Date: Tue, 31 Jan 2017 12:38:33 +0000 X-Gmail-Original-Message-ID: Message-ID: To: PHP Internals Content-Type: multipart/alternative; boundary=f403045e72d2701dc70547633666 Subject: Re: [PHP-DEV] [RFC][Discuss] Arrow Functions From: me@kelunik.com (Niklas Keller) --f403045e72d2701dc70547633666 Content-Type: text/plain; charset=UTF-8 Alain Williams schrieb am Di., 31. Jan. 2017, 13:20: > On Tue, Jan 31, 2017 at 01:06:25PM +0100, Nicolas Grekas wrote: > > Or just drop any "fn" or "function" keyword, eg > > > > ($x, $y) => foo($x, $y); > > > > array_map(($x) => $x + 1); > > That has the great advantage of being much as Javascript does this. > > > https://developer.mozilla.org/en/docs/Web/JavaScript/Reference/Functions/Arrow_functions As noted in the RFC, this isn't possible due to ambiguities with array keys and yield expressions with keys. Regards, Niklas > -- > Alain Williams > Linux/GNU Consultant - Mail systems, Web sites, Networking, Programmer, IT > Lecturer. > +44 (0) 787 668 0256 http://www.phcomp.co.uk/ > Parliament Hill Computers Ltd. Registration Information: > http://www.phcomp.co.uk/contact.php > #include > > -- > PHP Internals - PHP Runtime Development Mailing List > To unsubscribe, visit: http://www.php.net/unsub.php > > --f403045e72d2701dc70547633666--