Re: PATCH: anonymous functions in PHP
| From: | Sean Coates | Date: | Mon, 19 Mar 2007 22:35:24 +0000 |
| Subject: | Re: PATCH: anonymous functions in PHP | ||
| References: | 1 2 3 4 5 6 7 8 9 10 11 | Groups: | php.internals |
| Request: | Send a blank email to internals+get-28468@lists.php.net to get a copy of this message | ||
> Can't you just take the body of "create_function" with the syntax of
> the patch, and marry those two?
I already explained why this can't work, in this very thread. At least
not without hacking { and } to work (mostly) like " in this context.
> How does the current create_function handle this same scope issue?
create_function() takes a string. This string is interpolated at
runtime. There's an obvious distinction between local variables (they
look like \$something within the string, and parent vars: they look like
'. $var .' )
S