Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:65942 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 45021 invoked from network); 19 Feb 2013 13:22:30 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 19 Feb 2013 13:22:30 -0000 Authentication-Results: pb1.pair.com smtp.mail=dragoonis@gmail.com; spf=pass; sender-id=pass Authentication-Results: pb1.pair.com header.from=dragoonis@gmail.com; sender-id=pass Received-SPF: pass (pb1.pair.com: domain gmail.com designates 209.85.128.48 as permitted sender) X-PHP-List-Original-Sender: dragoonis@gmail.com X-Host-Fingerprint: 209.85.128.48 mail-qe0-f48.google.com Received: from [209.85.128.48] ([209.85.128.48:45871] helo=mail-qe0-f48.google.com) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id 48/C4-17768-59C73215 for ; Tue, 19 Feb 2013 08:22:30 -0500 Received: by mail-qe0-f48.google.com with SMTP id 3so3002202qea.35 for ; Tue, 19 Feb 2013 05:22:27 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:x-received:in-reply-to:references:date:message-id :subject:from:to:cc:content-type; bh=b+XdDJ+UycGNISFEQu4jMfkbtAqPHLxC9HToJVCVyxs=; b=uuaRrcrvpLs+yDyYl8EnPEwm19nOG8N0luHkXaVErbUXNzhiPK7lLUOaXr+w0Q1b0Y dy4mARGnYMLLbEHRMdB1dTW+8TRxzk5te3GWdACK1px+DeUge+NbWZdmc3GyE3o0XuRT Orq0DrfAhQuGIoDBZJZtq7WKB4vVLYvqIjto9ZoBsIb7LxfsKSS7CvqN0211BpzdcxPQ BSpr/DsIQz+TCDbqDIUz9apnUADJw+7wWCfmb7TYGlZHjbkQKPw9+dkqkC3VDFxQDlpQ 7X3mhUkYkcxS34a+GEoy3BPYB/JTMsB6lVfOER9tZGOY5IP3BdZpPZiz3ve91ukt74MK bACw== MIME-Version: 1.0 X-Received: by 10.49.128.231 with SMTP id nr7mr7107229qeb.49.1361280147241; Tue, 19 Feb 2013 05:22:27 -0800 (PST) Received: by 10.229.202.193 with HTTP; Tue, 19 Feb 2013 05:22:26 -0800 (PST) In-Reply-To: References: <8490FC41-2696-4948-83A1-3931674183B0@gmail.com> Date: Tue, 19 Feb 2013 13:22:26 +0000 Message-ID: To: Anthony Ferrara Cc: Marcello Duarte , PHP Internals Content-Type: multipart/alternative; boundary=047d7b6d9f1c9dba9904d613bb12 Subject: Re: [PHP-DEV] [RFC] Short syntax for anonymous functions From: dragoonis@gmail.com (Paul Dragoonis) --047d7b6d9f1c9dba9904d613bb12 Content-Type: text/plain; charset=ISO-8859-1 I also am not in favour of the syntax, it's too short and quirky. I'm honestly fine with 'function()' it's very explicit On Tue, Feb 19, 2013 at 1:20 PM, Anthony Ferrara wrote: > Marcello, > > > On Tue, Feb 19, 2013 at 7:57 AM, Marcello Duarte > wrote: > > > Inspired by Sara, here is another RFC, I finally got around to draft: > > > > https://wiki.php.net/rfc/short-syntax-for-anonymous-function > > > > Please feedback, > > -- > > Marcello Duarte > > > > > I like the concept. I dislike the syntax. It looks too much like a JSON > object declaration, and it feels like it should be returning an object > instead of a closure/anonymous function. Additionally, I don't like that > it's also a closure. Short functions like this should be for simple > functions... > > Perhaps: > > lambda $x: trim($x); > > $x: trim($x); > > Or something similar... > > Anthony > --047d7b6d9f1c9dba9904d613bb12--