1--TEST-- 2active_class_entry must be always correct (__METHOD__ should not depend on declaring function ce) 3--FILE-- 4<?php 5 6namespace Baz; 7 8class Foo { 9 public static function bar() { 10 function foo() { 11 var_dump(__FUNCTION__); 12 var_dump(__METHOD__); 13 var_dump(__CLASS__); 14 } 15 16 foo(); 17 18 var_dump(__FUNCTION__); 19 var_dump(__METHOD__); 20 var_dump(__CLASS__); 21 22 return function() {var_dump(__FUNCTION__); var_dump(__METHOD__); var_dump(__CLASS__); }; 23 } 24} 25 26$c = Foo::bar(); 27 28$c(); 29?> 30--EXPECTF-- 31string(7) "Baz\foo" 32string(7) "Baz\foo" 33string(0) "" 34string(3) "bar" 35string(12) "Baz\Foo::bar" 36string(7) "Baz\Foo" 37string(%d) "{closure:%s:%d}" 38string(%d) "{closure:%s:%d}" 39string(7) "Baz\Foo" 40