PHP 4.0 Bug #1853: function pointers on class members don't work
| From: | christophe dot massiot at mail dot dotcom dot fr | Date: | Fri, 23 Jul 1999 21:42:26 +0000 |
| Subject: | PHP 4.0 Bug #1853: function pointers on class members don't work | ||
| Groups: | php.dev | ||
| Request: | Send a blank email to php-dev+get-9068@lists.php.net to get a copy of this message | ||
From: christophe.massiot@mail.dotcom.fr
Operating system: Debian GNU/Linux
PHP version: 4.0 Beta 1
PHP Bug Type: Feature/Change Request
Bug description: function pointers on class members don't work
The following script doesn't work in PHP4 :
<?
class titi {
function toto() { echo "meuuh"; }
function main() {
$var = "\$this->toto";
$var();
}
}
$titi = new titi;
$titi->main();
?>
Notice that it doesn't work in PHP3 either, so it is not a bug report, rather a feature
request.
It doesn't make sense in PHP3, but if you intend to push OO features in PHP4, function pointers
might be pretty useful.