Bug 1613985 - Use default for equivalent-to-default constructors/destructors in dom/push. r=smaug

Depends on D66025

Differential Revision: https://phabricator.services.mozilla.com/D66027

--HG--
extra : moz-landing-system : lando
This commit is contained in:
Simon Giesecke 2020-03-09 15:05:52 +00:00
Родитель d81853cb9d
Коммит 7c764ee1da
3 изменённых файлов: 21 добавлений и 20 удалений

Просмотреть файл

@ -132,7 +132,7 @@ class GetSubscriptionResultRunnable final : public WorkerRunnable {
}
private:
~GetSubscriptionResultRunnable() {}
~GetSubscriptionResultRunnable() = default;
RefPtr<PromiseWorkerProxy> mProxy;
nsresult mStatus;
@ -185,7 +185,7 @@ class GetSubscriptionCallback final : public nsIPushSubscriptionCallback {
}
protected:
~GetSubscriptionCallback() {}
~GetSubscriptionCallback() = default;
private:
RefPtr<PromiseWorkerProxy> mProxy;
@ -272,7 +272,7 @@ class GetSubscriptionRunnable final : public Runnable {
}
private:
~GetSubscriptionRunnable() {}
~GetSubscriptionRunnable() = default;
RefPtr<PromiseWorkerProxy> mProxy;
nsString mScope;
@ -308,7 +308,7 @@ class PermissionResultRunnable final : public WorkerRunnable {
}
private:
~PermissionResultRunnable() {}
~PermissionResultRunnable() = default;
RefPtr<PromiseWorkerProxy> mProxy;
nsresult mStatus;
@ -340,7 +340,7 @@ class PermissionStateRunnable final : public Runnable {
}
private:
~PermissionStateRunnable() {}
~PermissionStateRunnable() = default;
RefPtr<PromiseWorkerProxy> mProxy;
};
@ -363,7 +363,7 @@ PushManager::PushManager(const nsAString& aScope) : mScope(aScope) {
#endif
}
PushManager::~PushManager() {}
PushManager::~PushManager() = default;
NS_IMPL_CYCLE_COLLECTION_WRAPPERCACHE(PushManager, mGlobal, mImpl)
NS_IMPL_CYCLE_COLLECTING_ADDREF(PushManager)

Просмотреть файл

@ -24,9 +24,9 @@
namespace mozilla {
namespace dom {
PushNotifier::PushNotifier() {}
PushNotifier::PushNotifier() = default;
PushNotifier::~PushNotifier() {}
PushNotifier::~PushNotifier() = default;
NS_IMPL_CYCLE_COLLECTION_0(PushNotifier)
@ -149,7 +149,7 @@ nsresult PushNotifier::Dispatch(PushDispatcher& aDispatcher) {
PushData::PushData(const nsTArray<uint8_t>& aData) : mData(aData) {}
PushData::~PushData() {}
PushData::~PushData() = default;
NS_IMPL_CYCLE_COLLECTION_0(PushData)
@ -205,7 +205,7 @@ PushData::Binary(nsTArray<uint8_t>& aData) {
PushMessage::PushMessage(nsIPrincipal* aPrincipal, nsIPushData* aData)
: mPrincipal(aPrincipal), mData(aData) {}
PushMessage::~PushMessage() {}
PushMessage::~PushMessage() = default;
NS_IMPL_CYCLE_COLLECTION(PushMessage, mPrincipal, mData)
@ -239,7 +239,7 @@ PushDispatcher::PushDispatcher(const nsACString& aScope,
nsIPrincipal* aPrincipal)
: mScope(aScope), mPrincipal(aPrincipal) {}
PushDispatcher::~PushDispatcher() {}
PushDispatcher::~PushDispatcher() = default;
nsresult PushDispatcher::HandleNoChildProcesses() { return NS_OK; }
@ -308,7 +308,7 @@ PushMessageDispatcher::PushMessageDispatcher(
mMessageId(aMessageId),
mData(aData) {}
PushMessageDispatcher::~PushMessageDispatcher() {}
PushMessageDispatcher::~PushMessageDispatcher() = default;
nsresult PushMessageDispatcher::NotifyObservers() {
nsCOMPtr<nsIPushData> data;
@ -357,7 +357,7 @@ PushSubscriptionChangeDispatcher::PushSubscriptionChangeDispatcher(
const nsACString& aScope, nsIPrincipal* aPrincipal)
: PushDispatcher(aScope, aPrincipal) {}
PushSubscriptionChangeDispatcher::~PushSubscriptionChangeDispatcher() {}
PushSubscriptionChangeDispatcher::~PushSubscriptionChangeDispatcher() = default;
nsresult PushSubscriptionChangeDispatcher::NotifyObservers() {
return DoNotifyObservers(mPrincipal, OBSERVER_TOPIC_SUBSCRIPTION_CHANGE,
@ -396,7 +396,8 @@ PushSubscriptionModifiedDispatcher::PushSubscriptionModifiedDispatcher(
const nsACString& aScope, nsIPrincipal* aPrincipal)
: PushDispatcher(aScope, aPrincipal) {}
PushSubscriptionModifiedDispatcher::~PushSubscriptionModifiedDispatcher() {}
PushSubscriptionModifiedDispatcher::~PushSubscriptionModifiedDispatcher() =
default;
nsresult PushSubscriptionModifiedDispatcher::NotifyObservers() {
return DoNotifyObservers(mPrincipal, OBSERVER_TOPIC_SUBSCRIPTION_MODIFIED,
@ -423,7 +424,7 @@ PushErrorDispatcher::PushErrorDispatcher(const nsACString& aScope,
uint32_t aFlags)
: PushDispatcher(aScope, aPrincipal), mMessage(aMessage), mFlags(aFlags) {}
PushErrorDispatcher::~PushErrorDispatcher() {}
PushErrorDispatcher::~PushErrorDispatcher() = default;
nsresult PushErrorDispatcher::NotifyObservers() { return NS_OK; }

Просмотреть файл

@ -45,7 +45,7 @@ class UnsubscribeResultCallback final : public nsIUnsubscribeResultCallback {
}
private:
~UnsubscribeResultCallback() {}
~UnsubscribeResultCallback() = default;
RefPtr<Promise> mPromise;
};
@ -81,7 +81,7 @@ class UnsubscribeResultRunnable final : public WorkerRunnable {
}
private:
~UnsubscribeResultRunnable() {}
~UnsubscribeResultRunnable() = default;
RefPtr<PromiseWorkerProxy> mProxy;
nsresult mStatus;
@ -117,7 +117,7 @@ class WorkerUnsubscribeResultCallback final
}
private:
~WorkerUnsubscribeResultCallback() {}
~WorkerUnsubscribeResultCallback() = default;
RefPtr<PromiseWorkerProxy> mProxy;
};
@ -168,7 +168,7 @@ class UnsubscribeRunnable final : public Runnable {
}
private:
~UnsubscribeRunnable() {}
~UnsubscribeRunnable() = default;
RefPtr<PromiseWorkerProxy> mProxy;
nsString mScope;
@ -200,7 +200,7 @@ PushSubscription::PushSubscription(nsIGlobalObject* aGlobal,
mOptions = new PushSubscriptionOptions(mGlobal, std::move(aAppServerKey));
}
PushSubscription::~PushSubscription() {}
PushSubscription::~PushSubscription() = default;
NS_IMPL_CYCLE_COLLECTION_WRAPPERCACHE(PushSubscription, mGlobal, mOptions)
NS_IMPL_CYCLE_COLLECTING_ADDREF(PushSubscription)