1
0
mirror of https://github.com/php/php-src.git synced 2026-03-29 03:32:20 +02:00
Files
archived-php-src/ext/reflection/tests/bug67068.phpt

18 lines
415 B
PHP

--TEST--
Bug #67068 (ReflectionFunction::getClosure returns something that doesn't report as a closure)
--FILE--
<?php
class MyClass {
public function method() {}
}
$object = new MyClass;
$reflector = new \ReflectionMethod($object, 'method');
$closure = $reflector->getClosure($object);
$closureReflector = new \ReflectionFunction($closure);
var_dump($closureReflector->isClosure());
?>
--EXPECT--
bool(true)