fix: Woverloaded-virtual and Wdelete-abstract-non-virtual-dtor warnings (#25)

This commit is contained in:
Robo 2023-04-22 00:28:08 +09:00 committed by GitHub
parent b9c5bec7bd
commit 1a64245a1a
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
5 changed files with 1 additions and 9 deletions

View File

@ -13,6 +13,7 @@ using namespace Napi;
class Policy
{
public:
virtual ~Policy() {}
virtual bool refresh() = 0;
virtual Value getValue(Env env) const = 0;
const std::string name;

View File

@ -27,8 +27,6 @@ public:
void OnExecute(Napi::Env env);
void Execute(const ExecutionProgress &progress);
void OnOK();
void OnError();
void OnProgress(const Policy *const *policies, size_t count);
void Dispose();

View File

@ -21,7 +21,5 @@ void PolicyWatcher::AddStringPolicy(const std::string name) {}
void PolicyWatcher::AddNumberPolicy(const std::string name) {}
void PolicyWatcher::OnExecute(Napi::Env env) {}
void PolicyWatcher::Execute(const ExecutionProgress &progress) {}
void PolicyWatcher::OnOK() {}
void PolicyWatcher::OnError() {}
void PolicyWatcher::OnProgress(const Policy *const *policies, size_t count) {}
void PolicyWatcher::Dispose() {}

View File

@ -21,7 +21,5 @@ void PolicyWatcher::AddStringPolicy(const std::string name) {}
void PolicyWatcher::AddNumberPolicy(const std::string name) {}
void PolicyWatcher::OnExecute(Napi::Env env) {}
void PolicyWatcher::Execute(const ExecutionProgress &progress) {}
void PolicyWatcher::OnOK() {}
void PolicyWatcher::OnError() {}
void PolicyWatcher::OnProgress(const Policy *const *policies, size_t count) {}
void PolicyWatcher::Dispose() {}

View File

@ -83,9 +83,6 @@ void PolicyWatcher::Execute(const ExecutionProgress &progress)
}
}
void PolicyWatcher::OnOK() {}
void PolicyWatcher::OnError() {}
void PolicyWatcher::OnProgress(const Policy *const *policies, size_t count)
{
HandleScope scope(Env());