Re: Re: PATCH: anonymous functions in PHP

From: Date: Mon, 19 Mar 2007 00:45:29 +0000
Subject: Re: Re: PATCH: anonymous functions in PHP
References: 1 2  Groups: php.internals 
Request: Send a blank email to internals+get-28402@lists.php.net to get a copy of this message
So, the question is, do we want this in PHP? yes, please.
Anonymous function declaration is one of the things I've always loved in Ruby and JavaScript - I for one would _love to see this_ in php. -- Jim R. Wilson (jimbojw) On 3/18/07, Wez Furlong <wez@omniti.com> wrote:
I found another flaw; when used in a loop it keeps trying to declare the same function over and over. I think this is because the ZEND_DECLARE_FUNCTION opcode is emitted as part of the arg list building op sequence. I'm poking to find an elegant way to fix that. --Wez. On Mar 18, 2007, at 7:41 PM, Wez Furlong wrote: You can find my prototype patch at http://pastebin.ca/400871 (against PHP_5_2) There's one minor flaw in my implementation for ZTS enabled systems (just need to move the anon function counter into CG() to solve that. -- PHP Internals - PHP Runtime Development Mailing List To unsubscribe, visit: http://www.php.net/unsub.php


« previous php.internals (#28402) next »