From c7193fcd419f206a20ad4616e72b7e14c0dfd297 Mon Sep 17 00:00:00 2001 From: Lioncash Date: Mon, 6 Jul 2015 05:29:41 -0400 Subject: [PATCH] MMIO: Add missing override specifiers --- Source/Core/Core/HW/MMIO.cpp | 25 +++++++++++++------------ 1 file changed, 13 insertions(+), 12 deletions(-) diff --git a/Source/Core/Core/HW/MMIO.cpp b/Source/Core/Core/HW/MMIO.cpp index 2e82db2656..1ee72b892f 100644 --- a/Source/Core/Core/HW/MMIO.cpp +++ b/Source/Core/Core/HW/MMIO.cpp @@ -43,7 +43,7 @@ public: virtual ~ConstantHandlingMethod() {} - virtual void AcceptReadVisitor(ReadHandlingMethodVisitor& v) const + void AcceptReadVisitor(ReadHandlingMethodVisitor& v) const override { v.VisitConstant(value_); } @@ -66,7 +66,8 @@ class NopHandlingMethod : public WriteHandlingMethod public: NopHandlingMethod() {} virtual ~NopHandlingMethod() {} - virtual void AcceptWriteVisitor(WriteHandlingMethodVisitor& v) const + + void AcceptWriteVisitor(WriteHandlingMethodVisitor& v) const override { v.VisitNop(); } @@ -91,12 +92,12 @@ public: virtual ~DirectHandlingMethod() {} - virtual void AcceptReadVisitor(ReadHandlingMethodVisitor& v) const + void AcceptReadVisitor(ReadHandlingMethodVisitor& v) const override { v.VisitDirect(addr_, mask_); } - virtual void AcceptWriteVisitor(WriteHandlingMethodVisitor& v) const + void AcceptWriteVisitor(WriteHandlingMethodVisitor& v) const override { v.VisitDirect(addr_, mask_); } @@ -146,12 +147,12 @@ public: virtual ~ComplexHandlingMethod() {} - virtual void AcceptReadVisitor(ReadHandlingMethodVisitor& v) const + void AcceptReadVisitor(ReadHandlingMethodVisitor& v) const override { v.VisitComplex(&read_lambda_); } - virtual void AcceptWriteVisitor(WriteHandlingMethodVisitor& v) const + void AcceptWriteVisitor(WriteHandlingMethodVisitor& v) const override { v.VisitComplex(&write_lambda_); } @@ -300,17 +301,17 @@ void ReadHandler::ResetMethod(ReadHandlingMethod* method) { std::function ret; - virtual void VisitConstant(T value) + void VisitConstant(T value) override { ret = [value](u32) { return value; }; } - virtual void VisitDirect(const T* addr, u32 mask) + void VisitDirect(const T* addr, u32 mask) override { ret = [addr, mask](u32) { return *addr & mask; }; } - virtual void VisitComplex(const std::function* lambda) + void VisitComplex(const std::function* lambda) override { ret = *lambda; } @@ -356,17 +357,17 @@ void WriteHandler::ResetMethod(WriteHandlingMethod* method) { std::function ret; - virtual void VisitNop() + void VisitNop() override { ret = [](u32, T) {}; } - virtual void VisitDirect(T* ptr, u32 mask) + void VisitDirect(T* ptr, u32 mask) override { ret = [ptr, mask](u32, T val) { *ptr = val & mask; }; } - virtual void VisitComplex(const std::function* lambda) + void VisitComplex(const std::function* lambda) override { ret = *lambda; }