From: zmeigorin at comail dot ru Operating system: Windows/Irrelevant? PHP version: 4.3.6 PHP Bug Type: Scripting Engine problem Bug description: __call not invoked by call_user_func
Description: ------------ http://bugs.php.net/bug.php?id=19859 seems to be the same, but for PHP5. When using call_user_func/call_user_func_array, undefined methods are not handled by __call. Reproduce code: --------------- <?php class MyOverload { function __call($method,$args,&$return) { return $return = "__call result\n"; } } overload('MyOverload'); $obj =& new MyOverload; echo $obj->test(); echo call_user_func(array($obj,'test')); ?> Expected result: ---------------- __call result __call result Actual result: -------------- __call result Warning: call_user_func(myoverload::test): First argument is expected to be a valid callback -- Edit bug report at http://bugs.php.net/?id=28576&edit=1 -- Try a CVS snapshot (php4): http://bugs.php.net/fix.php?id=28576&r=trysnapshot4 Try a CVS snapshot (php5): http://bugs.php.net/fix.php?id=28576&r=trysnapshot5 Fixed in CVS: http://bugs.php.net/fix.php?id=28576&r=fixedcvs Fixed in release: http://bugs.php.net/fix.php?id=28576&r=alreadyfixed Need backtrace: http://bugs.php.net/fix.php?id=28576&r=needtrace Need Reproduce Script: http://bugs.php.net/fix.php?id=28576&r=needscript Try newer version: http://bugs.php.net/fix.php?id=28576&r=oldversion Not developer issue: http://bugs.php.net/fix.php?id=28576&r=support Expected behavior: http://bugs.php.net/fix.php?id=28576&r=notwrong Not enough info: http://bugs.php.net/fix.php?id=28576&r=notenoughinfo Submitted twice: http://bugs.php.net/fix.php?id=28576&r=submittedtwice register_globals: http://bugs.php.net/fix.php?id=28576&r=globals PHP 3 support discontinued: http://bugs.php.net/fix.php?id=28576&r=php3 Daylight Savings: http://bugs.php.net/fix.php?id=28576&r=dst IIS Stability: http://bugs.php.net/fix.php?id=28576&r=isapi Install GNU Sed: http://bugs.php.net/fix.php?id=28576&r=gnused Floating point limitations: http://bugs.php.net/fix.php?id=28576&r=float
