Re: PATCH: anonymous functions in PHP

From: Date: Mon, 19 Mar 2007 20:59:17 +0000
Subject: Re: PATCH: anonymous functions in PHP
References: 1 2 3 4 5 6 7 8 9 10  Groups: php.internals 
Request: Send a blank email to internals+get-28445@lists.php.net to get a copy of this message
What about just having a function that allows retrieving variables from the parent scope?
    mixed seek_var( $name [, $levels=1, [ $startLevel=0 ] ] )
How you are going to know where "parent scope" is? It can even be not existing anymore, or can be separated by any number of parameter passing. Remember that the function is defined at compile-time, but invoked at run-time by some other function. -- Stanislav Malyshev, Zend Products Engineer stas@zend.com http://www.zend.com/

« previous php.internals (#28445) next »