>
>
> This is a bug. Please report it on https://bugs.php.net/
>
> See https://3v4l.org/vFgh0
>
> https://github.com/php/php-src/commit/f9f8c1c79cac1b03279190e0c5513a51881615f9
> https://github.com/php/php-src/pull/6811
>
> Best Regards,
> Kamil
>
Thank you! Reported as https://bugs.php.net/bug.ph
Hi Benjamin,
This is a bug. Please report it on https://bugs.php.net/
See https://3v4l.org/vFgh0
https://github.com/php/php-src/commit/f9f8c1c79cac1b03279190e0c5513a51881615f9
https://github.com/php/php-src/pull/6811
Best Regards,
Kamil
Hi internals,
I noticed a change of behaviour on PHP 8.1:
https://3v4l.org/DoG4A
```
// depth 1
$a = new \stdClass();
// depth 2
$b = new \stdClass();
$b->x = $a;
// depth 3
$c = new \stdClass();
$c->x = [$a];
var_export(json_encode($a, 0, 0)); echo "\n";
var_export(json_encode($b, 0, 1)); ec