Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:46822 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 7513 invoked from network); 19 Jan 2010 18:13:43 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 19 Jan 2010 18:13:43 -0000 Authentication-Results: pb1.pair.com smtp.mail=ceo@l-i-e.com; spf=pass; sender-id=pass Authentication-Results: pb1.pair.com header.from=ceo@l-i-e.com; sender-id=pass Received-SPF: pass (pb1.pair.com: domain l-i-e.com designates 67.139.134.202 as permitted sender) X-PHP-List-Original-Sender: ceo@l-i-e.com X-Host-Fingerprint: 67.139.134.202 o2.hostbaby.com FreeBSD 4.7-5.2 (or MacOS X 10.2-10.3) (2) Received: from [67.139.134.202] ([67.139.134.202:4546] helo=o2.hostbaby.com) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id 38/00-29385-556F55B4 for ; Tue, 19 Jan 2010 13:13:42 -0500 Received: (qmail 11402 invoked by uid 98); 19 Jan 2010 18:13:41 -0000 Received: from localhost by o2.hostbaby.com (envelope-from , uid 1013) with qmail-scanner-2.05 (clamdscan: 0.88.7/10312. Clear:RC:1(127.0.0.1):. Processed in 0.072121 secs); 19 Jan 2010 18:13:41 -0000 Received: from localhost (HELO l-i-e.com) (127.0.0.1) by localhost with SMTP; 19 Jan 2010 18:13:41 -0000 Received: from webmail (SquirrelMail authenticated user ceo@l-i-e.com) by www.l-i-e.com with HTTP; Tue, 19 Jan 2010 12:13:41 -0600 (CST) Message-ID: <3722.98.193.1263924821.squirrel@www.l-i-e.com> In-Reply-To: <4B55D850.8000604@zend.com> References: <4B54FC87.8070106@zend.com> <4F.56.22457.408955B4@pb1.pair.com> <4B55D850.8000604@zend.com> Date: Tue, 19 Jan 2010 12:13:41 -0600 (CST) To: "Stanislav Malyshev" Cc: "Michael Wallner" , internals@lists.php.net User-Agent: Hostbaby Webmail MIME-Version: 1.0 Content-Type: text/plain;charset=iso-8859-1 Content-Transfer-Encoding: 8bit X-Priority: 3 (Normal) Importance: Normal Subject: Re: [PHP-DEV] Re: function call chaining From: ceo@l-i-e.com ("Richard Lynch") On Tue, January 19, 2010 10:05 am, Stanislav Malyshev wrote: > Hi! > >> I'd rather see two other things that are missing, support for >> dynamic object and array de-referencing like >> (new class)->method() and get_array()["index"]. > > The second was next on my list, while the first seems to me kind of > exotic - why create object only to call one method and immediately > drop > it? Why this method is not static then? > >> I honestly don't see func()()()() make anything better in the >> world of a PHP programmer. > > You probably don't use closures, right? I use closures, though rarely. When I use one, I consider it exotic/obtuse/unusual enough to require self-documenting code, with a temp variable whose name include 'closure'. I do not want something as tiny as () to be all I have to clue in the new guy to a closure pattern/paradigm/algorithm. Maybe if I was typing all closures all day in PHP I'd see more need for it, but are you really doing this that often? -- Some people ask for gifts here. I just want you to buy an Indie CD for yourself: http://cdbaby.com/search/from/lynch