php-src/Zend/tests/frameless_throwing_destructor.phpt
Ilija Tovilo 631bc81607
Implement stackless internal function calls
Co-authored-by: Dmitry Stogov <dmitry@zend.com>

Closes GH-12461
2024-02-06 17:42:28 +01:00

19 lines
337 B
PHP

--TEST--
Frameless call with throwing destructor
--FILE--
<?php
class Foo {}
class Bar {
public function __destruct() {
throw new Exception();
}
}
in_array(new Foo(), [new Bar()], true);
?>
--EXPECTF--
Fatal error: Uncaught Exception in %s:%d
Stack trace:
#0 %s(%d): Bar->__destruct()
#1 {main}
thrown in %s on line %d