mirror of
https://github.com/php/php-src.git
synced 2024-11-23 18:04:36 +08:00
82479e89d0
I don't understand the rationale of fatal erroring here. It seems this should properly unprotect the compared elements when returning up the stack. Related to GH-14980
21 lines
371 B
PHP
21 lines
371 B
PHP
--TEST--
|
|
Bug #63882 (zend_std_compare_objects crash on recursion)
|
|
--FILE--
|
|
<?php
|
|
class Test { public $x = 5; }
|
|
|
|
$testobj1 = new Test;
|
|
$testobj2 = new Test;
|
|
$testobj1->x = $testobj1;
|
|
$testobj2->x = $testobj2;
|
|
|
|
try {
|
|
var_dump($testobj1 == $testobj2);
|
|
} catch (Error $e) {
|
|
echo $e->getMessage(), "\n";
|
|
}
|
|
|
|
?>
|
|
--EXPECT--
|
|
Nesting level too deep - recursive dependency?
|