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/Zend/tests/ |
Current File : //usr/local/src/php7/php-7.0.5/Zend/tests/closure_033.phpt |
--TEST-- Closure 033: Dynamic closure property and private function --FILE-- <?php class Test { public $func; function __construct() { $this->func = function() { echo __METHOD__ . "()\n"; }; } private function func() { echo __METHOD__ . "()\n"; } } $o = new Test; $f = $o->func; $f(); $o->func(); ?> ===DONE=== --EXPECTF-- {closure}() Fatal error: Uncaught Error: Call to private method Test::func() from context '' in %sclosure_033.php:%d Stack trace: #0 {main} thrown in %sclosure_033.php on line %d
Cokiee Shell Web 1.0, Coded By Razor
Neueste Kommentare