Closed rvosa closed 9 years ago
More progress: the MOP class is not actually fetching all methods with the attribute 'Destructor', so they weren't triggered by DESTROY. Since all these methods are in fact called _cleanup(), a workaround is to just call _cleanup on all the packages in @ISA that have it. These addresses most of the failing tests in 37-memory.t, except the ones that concern taxa inside project objects, for some reason.
FWIW all tests pass for me, even when I remove the last remaining skip
in t/37-memory. Can this issue be closed?
Objects that are inserted in Bio::Phylo::Listable containers appear to stay alive even beyond the point when the container goes out of scope and is cleaned up. This causes a memory leak that should be fixed. The behaviour is demonstrated in t/37-memory.t, which skips the problematic tests as of commit 340f24be5404bd9ce3d2a56cc406243fdc0d3d39