On 14 Jul 2008, at 18:12, Paul LeoNerd Evans wrote:
No amount of cycle checking in $some_object is going to find this cycle. If the cycled object is one like this; containing the only reference to
itself, then almost by definition there's nothing that could be walked
for memory cycles.


I've used Devel::Leak::Object[1] successfully in that kind of situation. It counts the number of blesses and destroys. It works well for the 'object makes a closure that references itself' scenario.

[1] http://search.cpan.org/dist/Devel-Leak-Object/

--
Andy Armstrong, Hexten



Reply via email to