weakrefs and avoiding bad gc cycles

Aaron Bentley aaron at aaronbentley.com
Tue Jun 14 18:26:59 UTC 2011


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

On 11-06-13 05:57 PM, Martin Pool wrote:
> When we want to for instance
> assert that something is definitely closed before the end of a test,
> there are better deterministic ways to do it without involving gc.

For objects where we do want to warn about failure to clean up, perhaps
they should register themselves with a singleton, and unregister on
cleanup?  Then we can ask the singleton whether any items still need
cleanup.

Aaron
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.11 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/

iEYEARECAAYFAk33p/MACgkQ0F+nu1YWqI3jEQCdF6sQXOi5uEOga937OLkrWPdx
hlYAn0WWyAg/Pp3eBEc8j1cBIe7P6o6K
=uVOK
-----END PGP SIGNATURE-----



More information about the bazaar mailing list