mirror of
https://github.com/tdinucci/6502-emulator.git
synced 2024-06-01 09:41:39 +00:00
17 lines
412 B
C++
17 lines
412 B
C++
|
#include "nop-opcode-handler.h"
|
||
|
|
||
|
const uint8_t NopOpcodeHandler::IMPLIED;
|
||
|
|
||
|
void NopOpcodeHandler::execute() {
|
||
|
auto instructionIndex = reg_man->get_program_counter()->get_value();
|
||
|
auto opcode = program->get_byte_at(instructionIndex);
|
||
|
|
||
|
switch (opcode) {
|
||
|
case IMPLIED:
|
||
|
move_program_counter(1);
|
||
|
break;
|
||
|
|
||
|
default:
|
||
|
throw_unexpected_opcode(opcode);
|
||
|
}
|
||
|
}
|