#48533 [Asn->Csd]: __callStatic is not invoked for private/protected methods
| From: | felipe@php.net | Date: | Fri, 12 Jun 2009 01:05:47 +0000 |
| Subject: | #48533 [Asn->Csd]: __callStatic is not invoked for private/protected methods | ||
| References: | 1 | Groups: | php.bugs |
| Request: | Send a blank email to php-bugs+get-138224@lists.php.net to get a copy of this message | ||
ID: 48533
Updated by: felipe@php.net
Reported By: ladislav at marek dot su
-Status: Assigned
+Status: Closed
Bug Type: Class/Object related
Operating System: Linux
PHP Version: 5.3CVS-2009-06-11 (snap)
Assigned To: felipe
New Comment:
This bug has been fixed in CVS.
Snapshots of the sources are packaged every three hours; this change
will be in the next snapshot. You can grab the snapshot at
http://snaps.php.net/.
Thank you for the report, and for helping us make PHP better.
Fixed in 5.3 and HEAD.
Previous Comments:
------------------------------------------------------------------------
[2009-06-11 20:04:17] ladislav at marek dot su
Description:
------------
__callStatic is not invoked when called method is defined as private or
protected.
Reproduce code:
---------------
class Test
{
private static function foo()
{
}
public static function __callStatic($name, $args)
{
var_dump($name);
}
}
Test::foo();
Expected result:
----------------
string(3) "foo"
Actual result:
--------------
Fatal error: Call to private method Test::foo() from context '' in %s
on line %i
------------------------------------------------------------------------
--
Edit this bug report at http://bugs.php.net/?id=48533&edit=1