mirror of
https://github.com/MoleskiCoder/EightBit.git
synced 2026-04-25 15:18:01 +00:00
Tidy up noexcept specification
This commit is contained in:
+10
-10
@@ -66,8 +66,8 @@ namespace EightBit {
|
||||
Signal<mc6809> ExecutingInstruction;
|
||||
Signal<mc6809> ExecutedInstruction;
|
||||
|
||||
int execute() final;
|
||||
[[nodiscard]] int step() final;
|
||||
int execute() noexcept final;
|
||||
[[nodiscard]] int step() noexcept final;
|
||||
|
||||
[[nodiscard]] constexpr auto& D() noexcept { return m_d; }
|
||||
[[nodiscard]] constexpr auto& A() noexcept { return D().high; }
|
||||
@@ -111,21 +111,21 @@ namespace EightBit {
|
||||
protected:
|
||||
// Default push/pop handlers
|
||||
|
||||
void push(uint8_t value) final;
|
||||
[[nodiscard]] uint8_t pop() final;
|
||||
void push(uint8_t value) noexcept final;
|
||||
[[nodiscard]] uint8_t pop() noexcept final;
|
||||
|
||||
// Interrupt (etc.) handlers
|
||||
|
||||
void handleRESET() final;
|
||||
void handleINT() final;
|
||||
void handleRESET() noexcept final;
|
||||
void handleINT() noexcept final;
|
||||
|
||||
// Bus reader/writers
|
||||
|
||||
void busWrite() final;
|
||||
uint8_t busRead() final;
|
||||
void busWrite() noexcept final;
|
||||
uint8_t busRead() noexcept final;
|
||||
|
||||
void call(register16_t destination) final;
|
||||
void ret() final;
|
||||
void call(register16_t destination) noexcept final;
|
||||
void ret() noexcept final;
|
||||
|
||||
private:
|
||||
const uint8_t RESETvector = 0xfe; // RESET vector
|
||||
|
||||
+10
-10
@@ -20,7 +20,7 @@ DEFINE_PIN_LEVEL_CHANGERS(BA, mc6809);
|
||||
DEFINE_PIN_LEVEL_CHANGERS(BS, mc6809);
|
||||
DEFINE_PIN_LEVEL_CHANGERS(RW, mc6809);
|
||||
|
||||
int EightBit::mc6809::step() {
|
||||
int EightBit::mc6809::step() noexcept {
|
||||
resetCycles();
|
||||
ExecutingInstruction.fire(*this);
|
||||
if (LIKELY(powered())) {
|
||||
@@ -49,7 +49,7 @@ void EightBit::mc6809::handleHALT() {
|
||||
raiseBS();
|
||||
}
|
||||
|
||||
void EightBit::mc6809::handleRESET() {
|
||||
void EightBit::mc6809::handleRESET() noexcept {
|
||||
BigEndianProcessor::handleRESET();
|
||||
memoryRead({ RESETvector, 0xff });
|
||||
raiseNMI();
|
||||
@@ -80,7 +80,7 @@ void EightBit::mc6809::handleNMI() {
|
||||
eat();
|
||||
}
|
||||
|
||||
void EightBit::mc6809::handleINT() {
|
||||
void EightBit::mc6809::handleINT() noexcept {
|
||||
BigEndianProcessor::handleINT();
|
||||
lowerBA();
|
||||
raiseBS();
|
||||
@@ -111,13 +111,13 @@ void EightBit::mc6809::handleFIRQ() {
|
||||
|
||||
//
|
||||
|
||||
void EightBit::mc6809::busWrite() {
|
||||
void EightBit::mc6809::busWrite() noexcept {
|
||||
tick();
|
||||
lowerRW();
|
||||
Processor::busWrite();
|
||||
}
|
||||
|
||||
uint8_t EightBit::mc6809::busRead() {
|
||||
uint8_t EightBit::mc6809::busRead() noexcept {
|
||||
tick();
|
||||
raiseRW();
|
||||
return Processor::busRead();
|
||||
@@ -125,21 +125,21 @@ uint8_t EightBit::mc6809::busRead() {
|
||||
|
||||
//
|
||||
|
||||
void EightBit::mc6809::call(register16_t destination) {
|
||||
void EightBit::mc6809::call(register16_t destination) noexcept {
|
||||
memoryRead(destination);
|
||||
eat();
|
||||
BigEndianProcessor::pushWord(PC());
|
||||
jump(destination);
|
||||
}
|
||||
|
||||
void EightBit::mc6809::ret() {
|
||||
void EightBit::mc6809::ret() noexcept {
|
||||
BigEndianProcessor::ret();
|
||||
eat();
|
||||
}
|
||||
|
||||
//
|
||||
|
||||
int EightBit::mc6809::execute() {
|
||||
int EightBit::mc6809::execute() noexcept {
|
||||
lowerBA();
|
||||
lowerBS();
|
||||
const bool prefixed = m_prefix10 || m_prefix11;
|
||||
@@ -628,11 +628,11 @@ void EightBit::mc6809::execute11() {
|
||||
|
||||
//
|
||||
|
||||
void EightBit::mc6809::push(const uint8_t value) {
|
||||
void EightBit::mc6809::push(const uint8_t value) noexcept {
|
||||
pushS(value);
|
||||
}
|
||||
|
||||
uint8_t EightBit::mc6809::pop() {
|
||||
uint8_t EightBit::mc6809::pop() noexcept {
|
||||
return popS();
|
||||
}
|
||||
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
Board::Board(const Configuration& configuration)
|
||||
: m_configuration(configuration) {}
|
||||
|
||||
void Board::raisePOWER() {
|
||||
void Board::raisePOWER() noexcept {
|
||||
|
||||
EightBit::Bus::raisePOWER();
|
||||
|
||||
@@ -26,7 +26,7 @@ void Board::raisePOWER() {
|
||||
accessAcia();
|
||||
}
|
||||
|
||||
void Board::lowerPOWER() {
|
||||
void Board::lowerPOWER() noexcept {
|
||||
|
||||
if (m_configuration.isProfileMode()) {
|
||||
m_profiler.EmitLine.connect([this](EightBit::ProfileLineEventArgs line) {
|
||||
|
||||
+2
-2
@@ -20,8 +20,8 @@ public:
|
||||
auto& CPU() { return m_cpu; }
|
||||
auto& ACIA() { return m_acia; }
|
||||
|
||||
void raisePOWER() final;
|
||||
void lowerPOWER() final;
|
||||
void raisePOWER() noexcept final;
|
||||
void lowerPOWER() noexcept final;
|
||||
|
||||
virtual void initialise() final;
|
||||
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
|
||||
Board::Board() {}
|
||||
|
||||
void Board::raisePOWER() {
|
||||
void Board::raisePOWER() noexcept {
|
||||
EightBit::Bus::raisePOWER();
|
||||
|
||||
CPU().raisePOWER();
|
||||
@@ -16,7 +16,7 @@ void Board::raisePOWER() {
|
||||
CPU().raiseHALT();
|
||||
}
|
||||
|
||||
void Board::lowerPOWER() {
|
||||
void Board::lowerPOWER() noexcept {
|
||||
CPU().lowerPOWER();
|
||||
EightBit::Bus::lowerPOWER();
|
||||
}
|
||||
|
||||
@@ -11,8 +11,8 @@ public:
|
||||
|
||||
constexpr EightBit::mc6809& CPU() noexcept { return m_cpu; }
|
||||
|
||||
void raisePOWER() final;
|
||||
void lowerPOWER() final;
|
||||
void raisePOWER() noexcept final;
|
||||
void lowerPOWER() noexcept final;
|
||||
|
||||
protected:
|
||||
void initialise() final;
|
||||
|
||||
Reference in New Issue
Block a user