php-src/Zend/tests/bug77627.phpt
2021-05-25 11:22:05 +02:00

16 lines
330 B
PHP

--TEST--
Fix for #77627 method_exists on Closure::__invoke without object returns false
--FILE--
<?php
var_dump(method_exists(Closure::class, "__invoke"));
var_dump(method_exists(Closure::class, "__INVOKE"));
$closure = function(){};
var_dump(method_exists($closure, "__INVOKE"));
?>
--EXPECT--
bool(true)
bool(true)
bool(true)