1--TEST--
2Observer: call_user_func_array() from namespace
3--SKIPIF--
4<?php if (!extension_loaded('zend-test')) die('skip: zend-test extension required'); ?>
5--INI--
6zend_test.observer.enabled=1
7zend_test.observer.observe_all=1
8--FILE--
9<?php
10namespace Test {
11    final class MyClass
12    {
13        public static function myMethod(string $msg)
14        {
15            echo 'MyClass::myMethod ' . $msg . PHP_EOL;
16        }
17    }
18
19    function my_function(string $msg)
20    {
21        echo 'my_function ' . $msg . PHP_EOL;
22    }
23
24    call_user_func_array('Test\\MyClass::myMethod', ['called']);
25    call_user_func_array('Test\\my_function', ['called']);
26}
27?>
28--EXPECTF--
29<!-- init '%s%eobserver_call_user_func_%d.php' -->
30<file '%s%eobserver_call_user_func_%d.php'>
31  <!-- init Test\MyClass::myMethod() -->
32  <Test\MyClass::myMethod>
33MyClass::myMethod called
34  </Test\MyClass::myMethod>
35  <!-- init Test\my_function() -->
36  <Test\my_function>
37my_function called
38  </Test\my_function>
39</file '%s%eobserver_call_user_func_%d.php'>
40