mozilla/addon-sdk — pull request #325 by mykmelez (2012-01-10 00:23:13+00:00)
Title: fix bug 672443 - reuse compartments between module sandboxes

This patch fixes bug 672443 by reusing compartments between module sandboxes created by an instance of the loader. It drastically reduces the number of entries for modules in about:memory?verbose when tested against the annotator example. It also happens to fix [bug 680821](https://bugzilla.mozilla.org/show_bug.cgi?id=680821), which is also being addressed by [pull request 323](https://github.com/mozilla/addon-sdk/pull/323). Since this pull request fixes both issues, it's the better one to merge.