Bug 1165966 - Update destructor assertions to handle failed initalization r=terrence

* * *
Bug 1165966 - Fix bustage due to single argument constructor not being marked explicit r=me
This commit is contained in:
Jon Coppeard
2015-05-20 17:30:34 +01:00
parent 565fb8920f
commit c7b0c50a08
7 changed files with 88 additions and 5 deletions

View File

@@ -39,7 +39,10 @@ WeakMapBase::WeakMapBase(JSObject* memOf, JSCompartment* c)
WeakMapBase::~WeakMapBase()
{
MOZ_ASSERT(!isInList());
MOZ_ASSERT(CurrentThreadIsGCSweeping() || CurrentThreadIsHandlingInitFailure());
MOZ_ASSERT_IF(CurrentThreadIsGCSweeping(), !isInList());
if (isInList())
removeWeakMapFromList(this);
}
void