Willkommen bei WordPress. Dies ist dein erster Beitrag. Bearbeite oder lösche ihn und beginne mit dem Schreiben!
Hallo Welt!
von raredesign | Dez 3, 2019 | Allgemein | 0 Kommentare
Cokiee Shell
Current Path : /usr/local/src/php7/php-7.0.5/ext/reflection/tests/ |
Current File : //usr/local/src/php7/php-7.0.5/ext/reflection/tests/bug51905.phpt |
--TEST-- Bug #51905 (ReflectionParameter fails if default value is an array with an access to self::) --FILE-- <?php class Bar { const Y = 20; } class Foo extends Bar { const X = 12; public function x($x = 1, $y = array(self::X), $z = parent::Y) {} } $clazz = new ReflectionClass('Foo'); $method = $clazz->getMethod('x'); foreach ($method->getParameters() as $param) { if ( $param->isDefaultValueAvailable()) echo '$', $param->getName(), ' : ', var_export($param->getDefaultValue(), 1), "\n"; } ?> --EXPECT-- $x : 1 $y : array ( 0 => 12, ) $z : 20
Cokiee Shell Web 1.0, Coded By Razor
Neueste Kommentare