1
0
ain48/editors/vim/syntax/ain48asm.vim

40 lines
1.2 KiB
VimL

" Vim syntax file
" Language: AIN-48 Assembly
" Maintainer: Annwan
" Latest Revision: 31 May 2026
if exists("b:current_syntax")
finish
endif
syn case ignore
syn keyword ain48Mnemonic add aeq aut cess cst dem dst dvd ei et i ilg imlg iplg irrv ivc lg mpl nam ncivc ncrv nec nei ni nni npi nui padd pdem pdvd pi pilg pimlg piplg pmpl prsd pstr rsd rv sc sim str tsc ui vel
" Senary constants
syn match ain48Immediate "#[Ss][0-5]\+"
syn match ain48Immediate "#-[Ss][0-5]\+"
" Octal constants
syn match ain48Immediate "#[Oo][0-7]\+"
syn match ain48Immediate "#-[Oo][0-7]\+"
" Decimal constants
syn match ain48Immediate "#[Xx][0-9]\+"
syn match ain48Immediate "#-[Xx][0-9]\+"
" Binary constants
syn match ain48Immediate "#[Bb][01]\+"
syn match ain48Immediate "#-[Bb][01]\+"
syn match ain48Register "%[0-7a-z]\+"
syn match ain48Directive "\.[a-z0-9_-]\+"
syn match ain48Comment ";.*$" contains=ain48Todo
syn keyword ain48Todo contained TODO FIXME NOTE
syn match ain48Label "^[a-zA-Z0-9_-]\+:"
hi link ain48Mnemonic Statement
hi link ain48Comment Comment
hi link ain48Immediate Constant
hi link ain48Directive PreProc
hi link ain48Label Label
hi link ain48Register Identifier