History log of /php-src/ext/spl/tests/gh8044.phpt (Results 1 – 1 of 1)
Revision (<<< Hide revision tags) (Show revision tags >>>) Date Author Comments
(<<< Hide modified files)
(Show modified files >>>)
Revision tags: php-8.2.0RC1, php-8.1.10
# 8b9679e8 30-Aug-2022 Tyson Andre

Make var_export/debug_zval_dump check for infinite recursion on the *object* (#9448)

Switch the recursion check from the result of `get_properties_for`
(the returned hash table of proper

Make var_export/debug_zval_dump check for infinite recursion on the *object* (#9448)

Switch the recursion check from the result of `get_properties_for`
(the returned hash table of properties) to just checking for
infinite recursion on the object.

- In order for a native datastructure to correctly implement
`*get_properties_for` for var_export's cycle detection,
it would need to return the exact same array every time prior to this PR.

Prior to this commit, the requirements for cycle detection
would prevent SplFixedArray or similar classes from returning a
temporary array that:

1. Wouldn't be affected by unexpected mutations from error handlers
2. Could be garbage collected instead.

show more ...