mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-11-26 14:22:01 +00:00
Bug 1624810 - Set the multi-zone JS holder flag on appropriate cycle collected classes r=mccr8
Set the flag on the affected classes, which are: - CallbackTimeoutHandler - nsJSArgArray - CallbackObject - Console - MessageEvent - IDBIndexCursor - ExtendableMessageEvent - JSPurpleBuffer Differential Revision: https://phabricator.services.mozilla.com/D68196 --HG-- extra : moz-landing-system : lando
This commit is contained in:
parent
7c60c2b222
commit
c1e3671c97
@ -103,7 +103,7 @@ CallbackTimeoutHandler::CallbackTimeoutHandler(
|
||||
mArgs = std::move(aArguments);
|
||||
}
|
||||
|
||||
NS_IMPL_CYCLE_COLLECTION_CLASS(CallbackTimeoutHandler)
|
||||
NS_IMPL_CYCLE_COLLECTION_MULTI_ZONE_JSHOLDER_CLASS(CallbackTimeoutHandler)
|
||||
|
||||
NS_IMPL_CYCLE_COLLECTION_UNLINK_BEGIN(CallbackTimeoutHandler)
|
||||
NS_IMPL_CYCLE_COLLECTION_UNLINK(mGlobal)
|
||||
|
@ -2776,7 +2776,7 @@ void nsJSArgArray::ReleaseJSObjects() {
|
||||
}
|
||||
|
||||
// QueryInterface implementation for nsJSArgArray
|
||||
NS_IMPL_CYCLE_COLLECTION_CLASS(nsJSArgArray)
|
||||
NS_IMPL_CYCLE_COLLECTION_MULTI_ZONE_JSHOLDER_CLASS(nsJSArgArray)
|
||||
|
||||
NS_IMPL_CYCLE_COLLECTION_UNLINK_BEGIN(nsJSArgArray)
|
||||
tmp->ReleaseJSObjects();
|
||||
|
@ -32,7 +32,7 @@ NS_INTERFACE_MAP_END
|
||||
NS_IMPL_CYCLE_COLLECTING_ADDREF(CallbackObject)
|
||||
NS_IMPL_CYCLE_COLLECTING_RELEASE(CallbackObject)
|
||||
|
||||
NS_IMPL_CYCLE_COLLECTION_CLASS(CallbackObject)
|
||||
NS_IMPL_CYCLE_COLLECTION_MULTI_ZONE_JSHOLDER_CLASS(CallbackObject)
|
||||
|
||||
NS_IMPL_CYCLE_COLLECTION_UNLINK_BEGIN(CallbackObject)
|
||||
tmp->ClearJSReferences();
|
||||
|
@ -783,7 +783,7 @@ class ConsoleProfileWorkerRunnable final : public ConsoleWorkerRunnable {
|
||||
nsString mAction;
|
||||
};
|
||||
|
||||
NS_IMPL_CYCLE_COLLECTION_CLASS(Console)
|
||||
NS_IMPL_CYCLE_COLLECTION_MULTI_ZONE_JSHOLDER_CLASS(Console)
|
||||
|
||||
NS_IMPL_CYCLE_COLLECTION_UNLINK_BEGIN(Console)
|
||||
NS_IMPL_CYCLE_COLLECTION_UNLINK(mGlobal)
|
||||
|
@ -17,7 +17,7 @@
|
||||
namespace mozilla {
|
||||
namespace dom {
|
||||
|
||||
NS_IMPL_CYCLE_COLLECTION_CLASS(MessageEvent)
|
||||
NS_IMPL_CYCLE_COLLECTION_MULTI_ZONE_JSHOLDER_CLASS(MessageEvent)
|
||||
|
||||
NS_IMPL_CYCLE_COLLECTION_UNLINK_BEGIN_INHERITED(MessageEvent, Event)
|
||||
tmp->mData.setUndefined();
|
||||
|
@ -812,9 +812,7 @@ NS_IMPL_CYCLE_COLLECTION_UNLINK_END
|
||||
|
||||
// Don't unlink mRequest or mSource in
|
||||
// NS_IMPL_CYCLE_COLLECTION_UNLINK_BEGIN_INHERITED!
|
||||
#define NS_IMPL_CYCLE_COLLECTION_IDBCURSOR_SUBCLASS(_subclassName) \
|
||||
NS_IMPL_CYCLE_COLLECTION_CLASS(_subclassName) \
|
||||
\
|
||||
#define NS_IMPL_CYCLE_COLLECTION_IDBCURSOR_SUBCLASS_METHODS(_subclassName) \
|
||||
NS_IMPL_CYCLE_COLLECTION_TRAVERSE_BEGIN_INHERITED(_subclassName, IDBCursor) \
|
||||
NS_IMPL_CYCLE_COLLECTION_TRAVERSE(mSource) \
|
||||
NS_IMPL_CYCLE_COLLECTION_TRAVERSE_END \
|
||||
@ -830,9 +828,18 @@ NS_IMPL_CYCLE_COLLECTION_UNLINK_END
|
||||
NS_IMPL_ADDREF_INHERITED(_subclassName, IDBCursor) \
|
||||
NS_IMPL_RELEASE_INHERITED(_subclassName, IDBCursor)
|
||||
|
||||
#define NS_IMPL_CYCLE_COLLECTION_IDBCURSOR_SUBCLASS(_subclassName) \
|
||||
NS_IMPL_CYCLE_COLLECTION_CLASS(_subclassName) \
|
||||
NS_IMPL_CYCLE_COLLECTION_IDBCURSOR_SUBCLASS_METHODS(_subclassName)
|
||||
|
||||
#define NS_IMPL_CYCLE_COLLECTION_IDBCURSOR_MULTI_ZONE_JSHOLDER_SUBCLASS( \
|
||||
_subclassName) \
|
||||
NS_IMPL_CYCLE_COLLECTION_MULTI_ZONE_JSHOLDER_CLASS(_subclassName) \
|
||||
NS_IMPL_CYCLE_COLLECTION_IDBCURSOR_SUBCLASS_METHODS(_subclassName)
|
||||
|
||||
NS_IMPL_CYCLE_COLLECTION_IDBCURSOR_SUBCLASS(IDBObjectStoreCursor)
|
||||
NS_IMPL_CYCLE_COLLECTION_IDBCURSOR_SUBCLASS(IDBObjectStoreKeyCursor)
|
||||
NS_IMPL_CYCLE_COLLECTION_IDBCURSOR_SUBCLASS(IDBIndexCursor)
|
||||
NS_IMPL_CYCLE_COLLECTION_IDBCURSOR_MULTI_ZONE_JSHOLDER_SUBCLASS(IDBIndexCursor)
|
||||
NS_IMPL_CYCLE_COLLECTION_IDBCURSOR_SUBCLASS(IDBIndexKeyCursor)
|
||||
|
||||
template <IDBCursor::Type CursorType>
|
||||
|
@ -21,7 +21,7 @@ namespace dom {
|
||||
NS_INTERFACE_MAP_BEGIN_CYCLE_COLLECTION(ModuleLoadRequest)
|
||||
NS_INTERFACE_MAP_END_INHERITING(ScriptLoadRequest)
|
||||
|
||||
NS_IMPL_CYCLE_COLLECTION_CLASS(ModuleLoadRequest)
|
||||
NS_IMPL_CYCLE_COLLECTION_MULTI_ZONE_JSHOLDER_CLASS(ModuleLoadRequest)
|
||||
|
||||
NS_IMPL_CYCLE_COLLECTION_UNLINK_BEGIN_INHERITED(ModuleLoadRequest,
|
||||
ScriptLoadRequest)
|
||||
|
@ -1253,7 +1253,7 @@ void ExtendableMessageEvent::GetPorts(nsTArray<RefPtr<MessagePort>>& aPorts) {
|
||||
aPorts = mPorts;
|
||||
}
|
||||
|
||||
NS_IMPL_CYCLE_COLLECTION_CLASS(ExtendableMessageEvent)
|
||||
NS_IMPL_CYCLE_COLLECTION_MULTI_ZONE_JSHOLDER_CLASS(ExtendableMessageEvent)
|
||||
|
||||
NS_IMPL_CYCLE_COLLECTION_UNLINK_BEGIN_INHERITED(ExtendableMessageEvent, Event)
|
||||
tmp->mData.setUndefined();
|
||||
|
@ -2361,7 +2361,7 @@ class JSPurpleBuffer {
|
||||
SegmentedVector<JSObject*, kSegmentSize, InfallibleAllocPolicy> mObjects;
|
||||
};
|
||||
|
||||
NS_IMPL_CYCLE_COLLECTION_CLASS(JSPurpleBuffer)
|
||||
NS_IMPL_CYCLE_COLLECTION_MULTI_ZONE_JSHOLDER_CLASS(JSPurpleBuffer)
|
||||
|
||||
NS_IMPL_CYCLE_COLLECTION_UNLINK_BEGIN(JSPurpleBuffer)
|
||||
tmp->Destroy();
|
||||
|
Loading…
Reference in New Issue
Block a user