mirror of
https://github.com/gryf/kickass-syntax-vim.git
synced 2026-04-25 09:21:24 +02:00
Compare commits
3 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| 2563e4eae7 | |||
| cb4627801a | |||
| 55efc1d2c4 |
+2
-2
@@ -22,7 +22,7 @@ You can also add to your vimrc file autocommand:
|
||||
|
||||
autocmd BufRead *.asm set filetype=kickass
|
||||
|
||||
From now on, all files with extension 'asm' will have brand new kickass
|
||||
From now on, all files with extension *asm* will have brand new kickass
|
||||
syntax.
|
||||
|
||||
Enjoy.
|
||||
@@ -32,4 +32,4 @@ Enjoy.
|
||||
.. _Vundle: https://github.com/gmarik/Vundle.vim
|
||||
.. _NeoBundle: https://github.com/Shougo/neobundle.vim
|
||||
.. _BitBucket: https://bitbucket.org/gryf/kickass-syntax-vim
|
||||
.. _GitHub: https://bitbucket.org/gryf/kickass-syntax-vim
|
||||
.. _GitHub: https://github.com/gryf/kickass-syntax-vim
|
||||
|
||||
+44
-4
@@ -1,10 +1,18 @@
|
||||
" Vim syntax file
|
||||
" Language: Assembler, KickAssembler
|
||||
" Maintainer: Roman 'gryf' Dobosz <gryf_esm@o2.pl>
|
||||
" Last Change: 2012-07-22
|
||||
" Version: 1.2
|
||||
" Last Change: 2019-08-04
|
||||
" Version: 1.5
|
||||
"
|
||||
" Changelog:
|
||||
" 1.5 Updated to KickAssembler 4.19. Added *, .zp, .encoding, .errorif and
|
||||
" .while directives. Added new import and preprocessor commands.
|
||||
"
|
||||
" 1.4 Updated to KickAssembler 3.42 changes. Added abbreviations for .byte,
|
||||
" .word and .dword. Added getPath and getFilename kickass functions.
|
||||
"
|
||||
" 1.3 Updated to KickAssembler 3.36 changes (added addAll and uget* methods)
|
||||
"
|
||||
" 1.2 Updated to KickAssembler 3.25 changes
|
||||
"
|
||||
" 1.1 Since in assembly languages 'everything is a label' there pretty hard
|
||||
@@ -124,11 +132,17 @@ syn match kickAssImmediate "#>\d\+\>"
|
||||
syn match kickAssDirective /\.\<pc\>/
|
||||
syn match kickAssDirective /\.\<align\>/
|
||||
syn match kickAssDirective /\.\<byte\>/
|
||||
syn match kickAssDirective /\.\<by\>/
|
||||
syn match kickAssDirective /\.\<word\>/
|
||||
syn match kickAssDirective /\.\<wo\>/
|
||||
syn match kickAssDirective /\.\<dword\>/
|
||||
syn match kickAssDirective /\.\<dw\>/
|
||||
syn match kickAssDirective /\.\<text\>/
|
||||
syn match kickAssDirective /\.\<fill\>/
|
||||
syn match kickAssDirective /\.\<pseudopc\>/
|
||||
syn match kickAssDirective /\.\<zp\>/
|
||||
syn match kickAssDirective /^\*[^\*]/he=e-1
|
||||
syn match kickAssDirective /\.\<encoding\>/
|
||||
|
||||
" modifiers
|
||||
syn match kickAssDirective /\.\<modify\>/
|
||||
@@ -139,6 +153,17 @@ syn match kickAssDirective "\.\<importonce\>"
|
||||
syn match kickAssDirective "\.\<import\>" nextgroup=kickAssImportType skipwhite
|
||||
syn keyword kickAssImportType source binary c64 text contained
|
||||
|
||||
" preprocessor/imports
|
||||
syn match kickAssInclude /#importonce\>/
|
||||
syn match kickAssInclude /#importif\>/
|
||||
syn match kickAssInclude /#import\>/
|
||||
syn match kickAssPreProc /#define\>/
|
||||
syn match kickAssPreProc /#undef\>/
|
||||
syn match kickAssPreProc /#if\>/
|
||||
syn match kickAssPreProc /#elif\>/
|
||||
syn match kickAssPreProc /#else\>/
|
||||
syn match kickAssPreProc /#endif\>/
|
||||
|
||||
" console output
|
||||
syn match kickAssDirective "\.\<print\>"
|
||||
syn match kickAssDirective "\.\<printnow\>"
|
||||
@@ -154,12 +179,16 @@ syn match kickAssDirective "\.\<lock\>"
|
||||
syn match kickAssDirective "\.\<define\>"
|
||||
syn match kickAssDirective "\.\<if\>"
|
||||
syn keyword kickAssDirective else
|
||||
syn match kickAssDirective "\.\<for\>"
|
||||
syn keyword kickAssDirective if
|
||||
syn keyword kickAssDirective var
|
||||
syn match kickAssDirective "\.\<for\>("he=e-1,hs=s+1
|
||||
syn match kickAssDirective "\.\<macro\>"
|
||||
syn match kickAssDirective "\.\<function\>"
|
||||
syn match kickAssDirective "\.\<return\>"
|
||||
syn match kickAssDirective "\.\<namespace\>"
|
||||
syn match kickAssDirective "\.\<filenamespace\>"
|
||||
syn match kickAssDirective "\.\<errorif\>"
|
||||
syn match kickAssDirective "\.\<while\>("he=e-1,hs=s+1
|
||||
|
||||
" special macros
|
||||
syn match kickAssMacroCall ":\<BasicUpstart2\?\>"
|
||||
@@ -190,6 +219,8 @@ syn match kickAssMethod "\.\<charAt\>("he=e-1,hs=s+1
|
||||
syn match kickAssMethod "\.\<substring\>("he=e-1,hs=s+1
|
||||
syn match kickAssMethod "\.\<asBoolean\>("he=e-1,hs=s+1
|
||||
syn match kickAssMethod "\.\<asNumber\>("he=e-1,hs=s+1
|
||||
syn match kickAssMethod "\.\<toLowerCase\>("he=e-1,hs=s+1
|
||||
syn match kickAssMethod "\.\<toUpperCase\>("he=e-1,hs=s+1
|
||||
|
||||
syn match kickAssFunction "\<toIntString\>("he=e-1
|
||||
syn match kickAssFunction "\<toBinaryString\>("he=e-1
|
||||
@@ -240,6 +271,7 @@ syn match kickAssMethod "\.\<remove\>("he=e-1,hs=s+1
|
||||
syn match kickAssMethod "\.\<shuffle\>("he=e-1,hs=s+1
|
||||
syn match kickAssMethod "\.\<reverse\>("he=e-1,hs=s+1
|
||||
syn match kickAssMethod "\.\<sort\>("he=e-1,hs=s+1
|
||||
syn match kickAssMethod "\.\<addAll\>("he=e-1,hs=s+1
|
||||
" READY.
|
||||
|
||||
" Hash - already defined names: get, remove
|
||||
@@ -292,6 +324,8 @@ syn keyword kickAssConstant BD_C64FILE BF_BITMAP_SINGLECOLOR BF_KOALA BF_FLI
|
||||
syn match kickAssFunction "\<LoadBinary\>("he=e-1
|
||||
syn match kickAssMethod "\.\<getSize\>("he=e-1,hs=s+1
|
||||
syn match kickAssFunction "\<LoadBinary\>("he=e-1
|
||||
syn match kickAssMethod "\.\<uget[a-zA-Z0-9]*\>("he=e-1,hs=s+1
|
||||
|
||||
|
||||
" Graphics files
|
||||
syn match kickAssFunction "\<LoadPicture\>("he=e-1
|
||||
@@ -316,6 +350,10 @@ syn match kickAssMethod "\.\<writeln\>("he=e-1,hs=s+1
|
||||
syn match kickAssDirective "\.\<kickAssert\>"
|
||||
syn match kickAssDirective "\.\<kickAsserterror\>"
|
||||
|
||||
" Misc
|
||||
syn match kickAssMethod "\<getPath\>("he=e-1,hs=s+1
|
||||
syn match kickAssMethod "\<getFilename\>("he=e-1,hs=s+1
|
||||
|
||||
if !exists("did_kickasm_syntax_inits")
|
||||
let did_kickasm_syntax_inits = 1
|
||||
|
||||
@@ -332,6 +370,8 @@ if !exists("did_kickasm_syntax_inits")
|
||||
hi def link kickAssTodo Todo
|
||||
|
||||
hi def link kickAssImportType Operator
|
||||
hi def link kickAssInclude Include
|
||||
hi def link kickAssPreProc PreProc
|
||||
|
||||
hi def link kickAssFunction Function
|
||||
hi def link kickAssMethod Function
|
||||
@@ -345,4 +385,4 @@ if !exists("did_kickasm_syntax_inits")
|
||||
hi def link kickAssDecNumber Number
|
||||
endif
|
||||
|
||||
let b:current_syntax = "kickasm"
|
||||
let b:current_syntax = "kickass"
|
||||
|
||||
Reference in New Issue
Block a user