xref: /php-src/ext/spl/tests/bug44144.phpt (revision 766ce8bd)
1--TEST--
2Bug #44144 (spl_autoload_functions() should return object instance when appropriate)
3--FILE--
4<?php
5class Foo {
6  public function nonstaticMethod() {}
7}
8$foo = new Foo;
9spl_autoload_register(array($foo, 'nonstaticMethod'));
10$funcs = spl_autoload_functions();
11var_dump($funcs);
12?>
13--EXPECTF--
14array(1) {
15  [0]=>
16  array(2) {
17    [0]=>
18    object(Foo)#%d (0) {
19    }
20    [1]=>
21    string(15) "nonstaticMethod"
22  }
23}
24