mirror of
https://github.com/php/php-src.git
synced 2026-03-24 08:12:21 +01:00
RFC: https://wiki.php.net/rfc/isreadable-iswriteable Fixes GH-15309 Fixes GH-16175 Closes GH-16209
21 lines
303 B
PHP
21 lines
303 B
PHP
--TEST--
|
|
Test ReflectionProperty::isWritable() invalid scope
|
|
--FILE--
|
|
<?php
|
|
|
|
class A {
|
|
public $prop;
|
|
}
|
|
|
|
$r = new ReflectionProperty('A', 'prop');
|
|
|
|
try {
|
|
$r->isWritable('B', null);
|
|
} catch (Error $e) {
|
|
echo $e::class, ': ', $e->getMessage(), "\n";
|
|
}
|
|
|
|
?>
|
|
--EXPECT--
|
|
Error: Class "B" not found
|