diff --git a/Source/Core/AudioCommon/XAudio2Stream.cpp b/Source/Core/AudioCommon/XAudio2Stream.cpp index 12954fc5bf..69c503f310 100644 --- a/Source/Core/AudioCommon/XAudio2Stream.cpp +++ b/Source/Core/AudioCommon/XAudio2Stream.cpp @@ -25,8 +25,7 @@ private: public: StreamingVoiceContext(IXAudio2* pXAudio2, CMixer* pMixer, Common::Event& pSyncEvent); - - ~StreamingVoiceContext(); + virtual ~StreamingVoiceContext(); void Stop(); void Play(); diff --git a/Source/Core/AudioCommon/XAudio2_7Stream.cpp b/Source/Core/AudioCommon/XAudio2_7Stream.cpp index 06fb645c95..1abf6d2096 100644 --- a/Source/Core/AudioCommon/XAudio2_7Stream.cpp +++ b/Source/Core/AudioCommon/XAudio2_7Stream.cpp @@ -25,8 +25,7 @@ private: public: StreamingVoiceContext2_7(IXAudio2* pXAudio2, CMixer* pMixer, Common::Event& pSyncEvent); - - ~StreamingVoiceContext2_7(); + virtual ~StreamingVoiceContext2_7(); void Stop(); void Play(); diff --git a/Source/Core/Common/Config/Section.h b/Source/Core/Common/Config/Section.h index 8b36ce157e..0a4662d156 100644 --- a/Source/Core/Common/Config/Section.h +++ b/Source/Core/Common/Config/Section.h @@ -27,6 +27,7 @@ class Section public: Section(LayerType layer, System system, const std::string& name); + virtual ~Section() = default; virtual bool Exists(const std::string& key) const; bool Delete(const std::string& key); diff --git a/Source/Core/Core/HW/MMIO.cpp b/Source/Core/Core/HW/MMIO.cpp index 8ee341554d..a6dcdeebd6 100644 --- a/Source/Core/Core/HW/MMIO.cpp +++ b/Source/Core/Core/HW/MMIO.cpp @@ -20,14 +20,14 @@ template class ReadHandlingMethod { public: - virtual ~ReadHandlingMethod() {} + virtual ~ReadHandlingMethod() = default; virtual void AcceptReadVisitor(ReadHandlingMethodVisitor& v) const = 0; }; template class WriteHandlingMethod { public: - virtual ~WriteHandlingMethod() {} + virtual ~WriteHandlingMethod() = default; virtual void AcceptWriteVisitor(WriteHandlingMethodVisitor& v) const = 0; }; @@ -39,7 +39,7 @@ class ConstantHandlingMethod : public ReadHandlingMethod { public: explicit ConstantHandlingMethod(T value) : value_(value) {} - virtual ~ConstantHandlingMethod() {} + virtual ~ConstantHandlingMethod() = default; void AcceptReadVisitor(ReadHandlingMethodVisitor& v) const override { v.VisitConstant(value_); @@ -62,7 +62,7 @@ class NopHandlingMethod : public WriteHandlingMethod { public: NopHandlingMethod() {} - virtual ~NopHandlingMethod() {} + virtual ~NopHandlingMethod() = default; void AcceptWriteVisitor(WriteHandlingMethodVisitor& v) const override { v.VisitNop(); } }; template @@ -79,7 +79,7 @@ class DirectHandlingMethod : public ReadHandlingMethod, public WriteHandlingM { public: DirectHandlingMethod(T* addr, u32 mask) : addr_(addr), mask_(mask) {} - virtual ~DirectHandlingMethod() {} + virtual ~DirectHandlingMethod() = default; void AcceptReadVisitor(ReadHandlingMethodVisitor& v) const override { v.VisitDirect(addr_, mask_); @@ -132,7 +132,7 @@ public: { } - virtual ~ComplexHandlingMethod() {} + virtual ~ComplexHandlingMethod() = default; void AcceptReadVisitor(ReadHandlingMethodVisitor& v) const override { v.VisitComplex(&read_lambda_); @@ -304,6 +304,8 @@ void ReadHandler::ResetMethod(ReadHandlingMethod* method) struct FuncCreatorVisitor : public ReadHandlingMethodVisitor { + virtual ~FuncCreatorVisitor() = default; + std::function ret; void VisitConstant(T value) override @@ -356,6 +358,8 @@ void WriteHandler::ResetMethod(WriteHandlingMethod* method) struct FuncCreatorVisitor : public WriteHandlingMethodVisitor { + virtual ~FuncCreatorVisitor() = default; + std::function ret; void VisitNop() override diff --git a/Source/VSProps/Base.props b/Source/VSProps/Base.props index 77732dc364..31336f3c07 100644 --- a/Source/VSProps/Base.props +++ b/Source/VSProps/Base.props @@ -117,6 +117,14 @@ Currently jits use some annoying code patterns which makes this common --> 4245;%(DisableSpecificWarnings) + +