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 : /proc/self/root/usr/local/src/php72/php-7.2.12/php-7.2.12/Zend/tests/try/ |
Current File : //proc/self/root/usr/local/src/php72/php-7.2.12/php-7.2.12/Zend/tests/try/catch_004.phpt |
--TEST-- Catching an exception in a constructor inside a static method --FILE-- <?php class MyObject { function fail() { throw new Exception(); } function __construct() { self::fail(); echo __METHOD__ . "() Must not be reached\n"; } function __destruct() { echo __METHOD__ . "() Must not be called\n"; } static function test() { try { new MyObject(); } catch(Exception $e) { echo "Caught\n"; } } } MyObject::test(); ?> ===DONE=== --EXPECT-- Caught ===DONE===
Cokiee Shell Web 1.0, Coded By Razor
Neueste Kommentare