note 93935 added to functions.anonymous

From: Date: Wed, 07 Oct 2009 14:41:46 +0000
Subject: note 93935 added to functions.anonymous
Groups: php.notes 
Request: Send a blank email to php-notes+get-161471@lists.php.net to get a copy of this message
The text above the third example tries to explain that anonymous functions can inherit variables from the parent scope, but fails to properly explain how this is done: namely using the "use" keyword in the function definition. The following page has a much more detailed explanation of closures in PHP 5.3: http://wiki.php.net/rfc/closures ---- Server IP: 213.249.64.162 Probable Submitter: 195.241.255.11 ---- Manual Page -- http://www.php.net/manual/en/functions.anonymous.php Edit -- https://master.php.net/note/edit/93935 Del: integrated -- https://master.php.net/note/delete/93935/integrated Del: useless -- https://master.php.net/note/delete/93935/useless Del: bad code -- https://master.php.net/note/delete/93935/bad+code Del: spam -- https://master.php.net/note/delete/93935/spam Del: non-english -- https://master.php.net/note/delete/93935/non-english Del: in docs -- https://master.php.net/note/delete/93935/in+docs Del: other reasons-- https://master.php.net/note/delete/93935 Reject -- https://master.php.net/note/reject/93935 Search -- https://master.php.net/manage/user-notes.php

« previous php.notes (#161471) next »