add tal syntax

This commit is contained in:
Nico 2022-01-14 13:55:06 +00:00
parent 010352ab33
commit 70665e1b84
1 changed files with 17 additions and 0 deletions

View File

@ -0,0 +1,17 @@
# thanks to makeworld for new instructions and multiline comment support
filetype: uxntal
detect:
filename: "\\.(tal|uxn|uxntal)$"
rules:
- identifier: "[@,;.&][^\ \n\r]+"
- constant: "[\"#'|$][^\ \n\r]+"
- statement: "\\b(BRK|LIT|INC|POP|DUP|NIP|SWP|OVR|ROT|EQU|NEQ|GTH|LTH|JMP|JCN|JSR|STH|LDZ|STZ|LDR|STR|LDA|STA|DEI|DEO|ADD|SUB|MUL|DIV|AND|ORA|EOR|SFT)[2rk]{0,3}\\b"
- comment:
start: "\\(\\ "
end: "\\ \\)"
rules: []
- symbol: "\\[|\\]"