Re: [RFC] Re: [PHP-DEV] __invoke() weirdness
| From: | Kenan R Sulayman | Date: | Sun, 04 Jan 2009 15:20:06 +0000 |
| Subject: | Re: [RFC] Re: [PHP-DEV] __invoke() weirdness | ||
| References: | 1 2 3 4 5 | Groups: | php.internals |
| Request: | Send a blank email to internals+get-42471@lists.php.net to get a copy of this message | ||
Hi Johannes,
<?
$o->foo = "foo"; $o->foo(); //Example 1
$o->bar = function(){}; $o->bar(); //Example 2
?>
The example 1 must not work, because PHP tries to call $o->foo() as a
function, but not $o->foo as description for the function.
To make example 2 working, the declaration has to be changed.
Thanks,
--
(c) Kenan Sulayman
Freelance Designer and Programmer
Life's Live Poetry
http://MyJurnal.tk/