Skip to content

Commit

Permalink
Rename Z80 prefix to SM83
Browse files Browse the repository at this point in the history
  • Loading branch information
Rangi42 committed Jan 24, 2025
1 parent 91d7ce5 commit 84f59e1
Show file tree
Hide file tree
Showing 2 changed files with 298 additions and 298 deletions.
96 changes: 48 additions & 48 deletions src/asm/lexer.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -139,53 +139,53 @@ struct CaseInsensitive {
// Tokens / keywords not handled here are handled in `yylex_NORMAL`'s switch.
// This assumes that no two keywords have the same name.
static std::unordered_map<std::string, int, CaseInsensitive, CaseInsensitive> keywordDict = {
{"ADC", T_(Z80_ADC) },
{"ADD", T_(Z80_ADD) },
{"AND", T_(Z80_AND) },
{"BIT", T_(Z80_BIT) },
{"CALL", T_(Z80_CALL) },
{"CCF", T_(Z80_CCF) },
{"CPL", T_(Z80_CPL) },
{"CP", T_(Z80_CP) },
{"DAA", T_(Z80_DAA) },
{"DEC", T_(Z80_DEC) },
{"DI", T_(Z80_DI) },
{"EI", T_(Z80_EI) },
{"HALT", T_(Z80_HALT) },
{"INC", T_(Z80_INC) },
{"JP", T_(Z80_JP) },
{"JR", T_(Z80_JR) },
{"LD", T_(Z80_LD) },
{"LDI", T_(Z80_LDI) },
{"LDD", T_(Z80_LDD) },
{"LDIO", T_(Z80_LDH) },
{"LDH", T_(Z80_LDH) },
{"NOP", T_(Z80_NOP) },
{"OR", T_(Z80_OR) },
{"POP", T_(Z80_POP) },
{"PUSH", T_(Z80_PUSH) },
{"RES", T_(Z80_RES) },
{"RETI", T_(Z80_RETI) },
{"RET", T_(Z80_RET) },
{"RLCA", T_(Z80_RLCA) },
{"RLC", T_(Z80_RLC) },
{"RLA", T_(Z80_RLA) },
{"RL", T_(Z80_RL) },
{"RRC", T_(Z80_RRC) },
{"RRCA", T_(Z80_RRCA) },
{"RRA", T_(Z80_RRA) },
{"RR", T_(Z80_RR) },
{"RST", T_(Z80_RST) },
{"SBC", T_(Z80_SBC) },
{"SCF", T_(Z80_SCF) },
{"SET", T_(Z80_SET) },
{"SLA", T_(Z80_SLA) },
{"SRA", T_(Z80_SRA) },
{"SRL", T_(Z80_SRL) },
{"STOP", T_(Z80_STOP) },
{"SUB", T_(Z80_SUB) },
{"SWAP", T_(Z80_SWAP) },
{"XOR", T_(Z80_XOR) },
{"ADC", T_(SM83_ADC) },
{"ADD", T_(SM83_ADD) },
{"AND", T_(SM83_AND) },
{"BIT", T_(SM83_BIT) },
{"CALL", T_(SM83_CALL) },
{"CCF", T_(SM83_CCF) },
{"CPL", T_(SM83_CPL) },
{"CP", T_(SM83_CP) },
{"DAA", T_(SM83_DAA) },
{"DEC", T_(SM83_DEC) },
{"DI", T_(SM83_DI) },
{"EI", T_(SM83_EI) },
{"HALT", T_(SM83_HALT) },
{"INC", T_(SM83_INC) },
{"JP", T_(SM83_JP) },
{"JR", T_(SM83_JR) },
{"LD", T_(SM83_LD) },
{"LDI", T_(SM83_LDI) },
{"LDD", T_(SM83_LDD) },
{"LDIO", T_(SM83_LDH) },
{"LDH", T_(SM83_LDH) },
{"NOP", T_(SM83_NOP) },
{"OR", T_(SM83_OR) },
{"POP", T_(SM83_POP) },
{"PUSH", T_(SM83_PUSH) },
{"RES", T_(SM83_RES) },
{"RETI", T_(SM83_RETI) },
{"RET", T_(SM83_RET) },
{"RLCA", T_(SM83_RLCA) },
{"RLC", T_(SM83_RLC) },
{"RLA", T_(SM83_RLA) },
{"RL", T_(SM83_RL) },
{"RRC", T_(SM83_RRC) },
{"RRCA", T_(SM83_RRCA) },
{"RRA", T_(SM83_RRA) },
{"RR", T_(SM83_RR) },
{"RST", T_(SM83_RST) },
{"SBC", T_(SM83_SBC) },
{"SCF", T_(SM83_SCF) },
{"SET", T_(SM83_SET) },
{"SLA", T_(SM83_SLA) },
{"SRA", T_(SM83_SRA) },
{"SRL", T_(SM83_SRL) },
{"STOP", T_(SM83_STOP) },
{"SUB", T_(SM83_SUB) },
{"SWAP", T_(SM83_SWAP) },
{"XOR", T_(SM83_XOR) },

{"NZ", T_(CC_NZ) },
{"Z", T_(CC_Z) },
Expand Down Expand Up @@ -315,7 +315,7 @@ static std::unordered_map<std::string, int, CaseInsensitive, CaseInsensitive> ke

{"RB", T_(POP_RB) },
{"RW", T_(POP_RW) },
// There is no `T_(POP_RL)`; it's handled before as `T_(Z80_RL)`
// There is no `T_(POP_RL)`; it's handled before as `T_(SM83_RL)`

{"EQU", T_(POP_EQU) },
{"EQUS", T_(POP_EQUS) },
Expand Down
Loading

0 comments on commit 84f59e1

Please sign in to comment.