mirror of
https://github.com/php/php-src.git
synced 2024-12-13 20:05:26 +08:00
24 lines
417 B
PHP
24 lines
417 B
PHP
--TEST--
|
|
Bug #50146 (property_exists: Closure object cannot have properties)
|
|
--FILE--
|
|
<?php
|
|
|
|
$obj = function(){};
|
|
|
|
var_dump(property_exists($obj,'foo'));
|
|
|
|
$ref = new ReflectionObject($obj);
|
|
var_dump($ref->hasProperty('b'));
|
|
|
|
var_dump(isset($obj->a));
|
|
|
|
?>
|
|
--EXPECTF--
|
|
bool(false)
|
|
bool(false)
|
|
|
|
Fatal error: Uncaught Error: Closure object cannot have properties in %s:%d
|
|
Stack trace:
|
|
#0 {main}
|
|
thrown in %s on line %d
|