Created
October 14, 2018 04:12
-
-
Save Xkeeper0/300b4402f1f18f3fbe91acb3647bb4af to your computer and use it in GitHub Desktop.
atom syntax for 6502 assembly using the asm6 assembler, enhanced from the original
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
'scopeName': 'source.assembly.6502.asm6' | |
'fileTypes': [ | |
'asm' | |
] | |
'name': '6502 Assembly (asm6)' | |
'patterns': [ | |
{ | |
'match': ';.*\\n?' | |
'name': 'comment.line.semicolon' | |
} | |
{ | |
'match': '\\b(?i)(adc|and|asl|bit|clc|cld|cli|clv|cmp|cpx|cpy|dec|dex|dey|eor|inc|inx|iny|lda|ldx|ldy|lsr|nop|ora|pha|php|pla|plp|rol|ror|sbc|sec|sed|sei|sta|stx|sty|tax|txa|tay|tya|tsx|txs)\\b' | |
'name': 'keyword' | |
} | |
{ | |
'match': '\\b(?i)(bcc|bcs|beq|bmi|bne|bpl|brk|bvc|bvs|jmp|jsr|rti|rts)\\b' | |
'name': 'keyword.control' | |
} | |
{ | |
'match': '(\\.|\\b)(?i)(DB|DW|BYTE|WORD|DCB|DCW|DC\\.B|DC\\.W|DSB|DSW|DS\\.B|DS\\.W|DL|DH|HEX)\\b' | |
'name': 'storage.type' | |
} | |
{ | |
'match': '(\\.|\\b)(?i)(BASE|ALIGN|PAD|FILLVALUE|ORG)\\b' | |
'name': 'storage.modifier' | |
} | |
{ | |
'match': '(\\.|\\b)(?i)(EQU|=|INCLUDE|INCSRC|INCBIN|BIN|IF|ELSEIF|ELSE|ENDIF)\\b' | |
'name': 'support.function' | |
} | |
{ | |
'match': '(\\.|\\b)(?i)(ERROR|ENUM|ENDE|REPT|ENDR|MACRO|ENDM|IFDEF|IFNDEF)\\b' | |
'name': 'constant.language' | |
} | |
{ | |
'match': '#?\\$[0-9a-fA-F]+' | |
'name': 'constant.numeric.hex' | |
} | |
{ | |
'match': '#?\\%[0-1]+' | |
'name': 'constant.numeric.binary' | |
} | |
{ | |
'match': '{[0-9]+}' | |
'name': 'variable.parameter.macro' | |
} | |
{ | |
'match': '(?i)(^\\s*([+-]+[a-z0-9]?*):?\\s|\\s([+-]+[a-z0-9]?*)(?=\\s*($|;)))' | |
'name': 'constant.language' | |
} | |
{ | |
'match': '(?i)(,\\s*X|,\\s*Y)\\b' | |
'name': 'variable.language' | |
} | |
] |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment