Bug 1613985 - Use default for equivalent-to-default constructors/destructors in dom/quota. r=dom-workers-and-storage-reviewers,janv

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

--HG--
extra : moz-landing-system : lando
This commit is contained in:
Simon Giesecke 2020-02-12 10:25:22 +00:00
Родитель fa114fcf6f
Коммит 861998c782
8 изменённых файлов: 28 добавлений и 28 удалений

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

@ -1093,7 +1093,7 @@ class CollectOriginsHelper final : public Runnable {
nsTArray<RefPtr<DirectoryLockImpl>>& aLocks);
private:
~CollectOriginsHelper() {}
~CollectOriginsHelper() = default;
NS_IMETHOD
Run() override;
@ -1232,7 +1232,7 @@ class FinalizeOriginEvictionOp : public OriginOperationBase {
void RunOnIOThreadImmediately();
private:
~FinalizeOriginEvictionOp() {}
~FinalizeOriginEvictionOp() = default;
virtual void Open() override;
@ -1270,7 +1270,7 @@ class NormalOriginOperationBase : public OriginOperationBase,
AssertIsOnOwningThread();
}
~NormalOriginOperationBase() {}
~NormalOriginOperationBase() = default;
private:
// Need to declare refcounting unconditionally, because
@ -1304,7 +1304,7 @@ class SaveOriginAccessTimeOp : public NormalOriginOperationBase {
}
private:
~SaveOriginAccessTimeOp() {}
~SaveOriginAccessTimeOp() = default;
virtual nsresult DoDirectoryWork(QuotaManager* aQuotaManager) override;
@ -1428,7 +1428,7 @@ class GetUsageOp final : public QuotaUsageRequestBase,
explicit GetUsageOp(const UsageRequestParams& aParams);
private:
~GetUsageOp() {}
~GetUsageOp() = default;
void ProcessOriginInternal(QuotaManager* aQuotaManager,
const PersistenceType aPersistenceType,
@ -1494,7 +1494,7 @@ class InitOp final : public QuotaRequestBase {
}
private:
~InitOp() {}
~InitOp() = default;
nsresult DoDirectoryWork(QuotaManager* aQuotaManager) override;
@ -1508,7 +1508,7 @@ class InitTemporaryStorageOp final : public QuotaRequestBase {
}
private:
~InitTemporaryStorageOp() {}
~InitTemporaryStorageOp() = default;
nsresult DoDirectoryWork(QuotaManager* aQuotaManager) override;
@ -1527,7 +1527,7 @@ class InitStorageAndOriginOp final : public QuotaRequestBase {
bool Init(Quota* aQuota) override;
private:
~InitStorageAndOriginOp() {}
~InitStorageAndOriginOp() = default;
nsresult DoDirectoryWork(QuotaManager* aQuotaManager) override;
@ -1543,7 +1543,7 @@ class ResetOrClearOp final : public QuotaRequestBase {
bool Init(Quota* aQuota) override;
private:
~ResetOrClearOp() {}
~ResetOrClearOp() = default;
void DeleteFiles(QuotaManager* aQuotaManager);
@ -1579,7 +1579,7 @@ class ClearOriginOp final : public ClearRequestBase {
bool Init(Quota* aQuota) override;
private:
~ClearOriginOp() {}
~ClearOriginOp() = default;
void GetResponse(RequestResponse& aResponse) override;
};
@ -1593,7 +1593,7 @@ class ClearDataOp final : public ClearRequestBase {
bool Init(Quota* aQuota) override;
private:
~ClearDataOp() {}
~ClearDataOp() = default;
void GetResponse(RequestResponse& aResponse) override;
};
@ -1619,7 +1619,7 @@ class PersistedOp final : public PersistRequestBase {
explicit PersistedOp(const RequestParams& aParams);
private:
~PersistedOp() {}
~PersistedOp() = default;
nsresult DoDirectoryWork(QuotaManager* aQuotaManager) override;
@ -1631,7 +1631,7 @@ class PersistOp final : public PersistRequestBase {
explicit PersistOp(const RequestParams& aParams);
private:
~PersistOp() {}
~PersistOp() = default;
nsresult DoDirectoryWork(QuotaManager* aQuotaManager) override;
@ -1940,7 +1940,7 @@ class StorageOperationBase {
NS_INLINE_DECL_REFCOUNTING(StorageOperationBase)
protected:
virtual ~StorageOperationBase() {}
virtual ~StorageOperationBase() = default;
nsresult GetDirectoryMetadata(nsIFile* aDirectory, int64_t& aTimestamp,
nsACString& aGroup, nsACString& aOrigin,
@ -2086,7 +2086,7 @@ class RepositoryOperationBase : public StorageOperationBase {
nsresult ProcessRepository();
protected:
virtual ~RepositoryOperationBase() {}
virtual ~RepositoryOperationBase() = default;
template <typename UpgradeMethod>
nsresult MaybeUpgradeClients(const OriginProps& aOriginsProps,

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

@ -127,7 +127,7 @@ class Client {
virtual void ShutdownWorkThreads() = 0;
protected:
virtual ~Client() {}
virtual ~Client() = default;
};
END_QUOTA_NAMESPACE

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

@ -35,7 +35,7 @@ class MemoryOutputStream final : public nsIOutputStream {
private:
MemoryOutputStream() : mOffset(0) {}
virtual ~MemoryOutputStream() {}
virtual ~MemoryOutputStream() = default;
NS_DECL_THREADSAFE_ISUPPORTS
NS_DECL_NSIOUTPUTSTREAM

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

@ -83,9 +83,9 @@ class DirectoryLock : public RefCountedObject {
void Log() const;
private:
DirectoryLock() {}
DirectoryLock() = default;
~DirectoryLock() {}
~DirectoryLock() = default;
};
class NS_NO_VTABLE OpenDirectoryListener : public RefCountedObject {
@ -95,7 +95,7 @@ class NS_NO_VTABLE OpenDirectoryListener : public RefCountedObject {
virtual void DirectoryLockFailed() = 0;
protected:
virtual ~OpenDirectoryListener() {}
virtual ~OpenDirectoryListener() = default;
};
struct OriginParams {

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

@ -118,7 +118,7 @@ class QuotaManagerService::PendingRequestInfo {
public:
explicit PendingRequestInfo(RequestBase* aRequest) : mRequest(aRequest) {}
virtual ~PendingRequestInfo() {}
virtual ~PendingRequestInfo() = default;
RequestBase* GetRequest() const { return mRequest; }

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

@ -24,7 +24,7 @@ class UsageResult : public nsIQuotaUsageResult {
uint64_t aLastAccessed);
private:
virtual ~UsageResult() {}
virtual ~UsageResult() = default;
NS_DECL_ISUPPORTS
NS_DECL_NSIQUOTAUSAGERESULT
@ -38,7 +38,7 @@ class OriginUsageResult : public nsIQuotaOriginUsageResult {
OriginUsageResult(uint64_t aUsage, uint64_t aFileUsage);
private:
virtual ~OriginUsageResult() {}
virtual ~OriginUsageResult() = default;
NS_DECL_ISUPPORTS
NS_DECL_NSIQUOTAORIGINUSAGERESULT
@ -52,7 +52,7 @@ class EstimateResult : public nsIQuotaEstimateResult {
EstimateResult(uint64_t aUsage, uint64_t aLimit);
private:
virtual ~EstimateResult() {}
virtual ~EstimateResult() = default;
NS_DECL_ISUPPORTS
NS_DECL_NSIQUOTAESTIMATERESULT

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

@ -66,7 +66,7 @@ class RequestResolver final : public nsIQuotaCallback {
NS_DECL_NSIQUOTACALLBACK
private:
~RequestResolver() {}
~RequestResolver() = default;
nsresult GetStorageEstimate(nsIVariant* aResult);
@ -688,7 +688,7 @@ StorageManager::StorageManager(nsIGlobalObject* aGlobal) : mOwner(aGlobal) {
MOZ_ASSERT(aGlobal);
}
StorageManager::~StorageManager() {}
StorageManager::~StorageManager() = default;
already_AddRefed<Promise> StorageManager::Persisted(ErrorResult& aRv) {
MOZ_ASSERT(mOwner);

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

@ -11,9 +11,9 @@
using namespace mozilla::net;
nsIndexedDBProtocolHandler::nsIndexedDBProtocolHandler() {}
nsIndexedDBProtocolHandler::nsIndexedDBProtocolHandler() = default;
nsIndexedDBProtocolHandler::~nsIndexedDBProtocolHandler() {}
nsIndexedDBProtocolHandler::~nsIndexedDBProtocolHandler() = default;
NS_IMPL_ISUPPORTS(nsIndexedDBProtocolHandler, nsIProtocolHandler,
nsISupportsWeakReference)