Arquivos
hhvm/hphp/test/quick/cuf08.php
T
Daniel Sloof 1ecc70eeff Fix arguments with __call and call_user_func_array
- Fix call_user_func_array to be Zend compliant, see new test
case

Closes #939

Differential Revision: D917994
2013-08-08 09:11:24 -07:00

24 linhas
480 B
PHP

<?php
class Test {
public function __call($method, $args) {
var_dump($args);
}
public static function __callStatic($method, $args) {
var_dump($args);
}
public function normal($args) {
var_dump($args);
}
}
$test = new Test();
call_user_func_array(array($test, 'magic'), array('bur' => 'bar'));
call_user_func_array(array($test, 'normal'), array('badum' => 'tss'));
call_user_func_array('Test::hi', array('bleep', 'bloop'));
$test->hi('hello world!');