diff --git a/Z80/test/Board.cpp b/Z80/test/Board.cpp index 359d6bb..c067551 100644 --- a/Z80/test/Board.cpp +++ b/Z80/test/Board.cpp @@ -10,7 +10,7 @@ void Board::powerOn() { CPU().reset(); } -void Board::powerOff() { +void Board::powerOff() noexcept { CPU().powerOff(); EightBit::Bus::powerOff(); } diff --git a/Z80/test/Board.h b/Z80/test/Board.h index e51e817..b4131c6 100644 --- a/Z80/test/Board.h +++ b/Z80/test/Board.h @@ -16,14 +16,14 @@ class Board : public EightBit::Bus { public: Board(const Configuration& configuration); - EightBit::Z80& CPU() { return m_cpu; } + EightBit::Z80& CPU() noexcept { return m_cpu; } - virtual void powerOn() final; - virtual void powerOff() final; + void powerOn() final; + void powerOff() noexcept final; protected: - virtual void initialise() final; - virtual EightBit::MemoryMapping mapping(uint16_t address) final { + void initialise() final; + EightBit::MemoryMapping mapping(uint16_t address) noexcept final { return { m_ram, 0x0000, 0xffff, EightBit::MemoryMapping::ReadWrite }; } diff --git a/Z80/test/Configuration.cpp b/Z80/test/Configuration.cpp deleted file mode 100644 index aacba64..0000000 --- a/Z80/test/Configuration.cpp +++ /dev/null @@ -1,8 +0,0 @@ -#include "stdafx.h" -#include "Configuration.h" - -Configuration::Configuration() noexcept -: m_debugMode(false), - m_profileMode(false), - m_romDirectory("roms") { -} diff --git a/Z80/test/Configuration.h b/Z80/test/Configuration.h index b5ac774..4ae06e8 100644 --- a/Z80/test/Configuration.h +++ b/Z80/test/Configuration.h @@ -4,9 +4,9 @@ #include -class Configuration { +class Configuration final { public: - Configuration() noexcept; + Configuration() noexcept = default; bool isDebugMode() const { return m_debugMode; @@ -24,7 +24,7 @@ public: m_profileMode = value; } - std::string getRomDirectory() const { + const std::string& getRomDirectory() const { return m_romDirectory; } @@ -33,8 +33,7 @@ public: } private: - bool m_debugMode; - bool m_profileMode; - - std::string m_romDirectory; + bool m_debugMode = false; + bool m_profileMode = false; + std::string m_romDirectory = "roms"; }; diff --git a/Z80/test/test_Z80.vcxproj b/Z80/test/test_Z80.vcxproj index a9c0daa..e822d3c 100644 --- a/Z80/test/test_Z80.vcxproj +++ b/Z80/test/test_Z80.vcxproj @@ -147,7 +147,6 @@ - Create Create diff --git a/Z80/test/test_Z80.vcxproj.filters b/Z80/test/test_Z80.vcxproj.filters index d2c0cf0..3f06f17 100644 --- a/Z80/test/test_Z80.vcxproj.filters +++ b/Z80/test/test_Z80.vcxproj.filters @@ -28,9 +28,6 @@ Source Files - - Source Files - Source Files