Re: [PATCH] [RFC] Closures and lambda functions in PHP

From: Date: Tue, 24 Jun 2008 16:55:06 +0000
Subject: Re: [PATCH] [RFC] Closures and lambda functions in PHP
References: 1  Groups: php.internals 
Request: Send a blank email to internals+get-38591@lists.php.net to get a copy of this message
Just to chime in on this thread; I like your implementation and (after reading through all the other comments so far), prefer the lexical keyword to import variables. As I've said before, the closure aspect of this is the hardest to gel into PHP, which deliberately avoids inheriting scopes. Since everyone has grown up explicitly managing this via the global keyword, I think it makes a lot of sense to use similar syntax for getting at those lexical values. I'm +1 for inclusion of this into the next release of PHP (post 5.3), and like Andrei, would love there to be a first class callable type for dynamic invocation of "regular" functions and methods. --Wez.

« previous php.internals (#38591) next »