mirror of
https://github.com/php/php-src.git
synced 2026-04-23 07:58:20 +02:00
21 lines
415 B
PHP
21 lines
415 B
PHP
--TEST--
|
|
GH-19926 (Assertion failure zend_hash_internal_pointer_reset_ex)
|
|
--FILE--
|
|
<?php
|
|
class ThrowingDestructor {
|
|
function __destruct() {
|
|
throw new Exception();
|
|
}
|
|
}
|
|
|
|
$arr = [new ThrowingDestructor(), new ThrowingDestructor()];
|
|
|
|
try {
|
|
array_splice($arr, 0, 2);
|
|
} catch (Exception $e) {
|
|
echo "Exception caught, no assertion failure\n";
|
|
}
|
|
?>
|
|
--EXPECT--
|
|
Exception caught, no assertion failure
|