diff --git a/syntax-files/Vim/prog8.vim b/syntax-files/Vim/prog8.vim index 58f4987da..75fdb8774 100644 --- a/syntax-files/Vim/prog8.vim +++ b/syntax-files/Vim/prog8.vim @@ -1,7 +1,7 @@ " Vim syntax file " Language: Prog8 " Maintainer: Elektron72 -" Latest Revision: 22 March 2021 +" Latest Revision: 23 March 2021 if exists("b:current_syntax") finish @@ -31,7 +31,7 @@ syn keyword prog8Conditional if_pl if_pos if_mi if_neg syn keyword prog8Conditional when syn keyword prog8Repeat for while in do until repeat syn match prog8Label "\<\w\+\>:" -syn keyword prog8Operator and or to downto as +syn keyword prog8Operator and or to downto as void syn match prog8Directive "\(^\|\s\)%\(target\|output\|launcher\|zeropage\)\>" syn match prog8Directive "\(^\|\s\)%\(zpreserved\|address\|import\|option\)\>" @@ -51,13 +51,21 @@ syn region prog8Expression start="(" end=")" transparent syn region prog8Array start="\[" end="\]" transparent +if !exists("g:prog8_no_highlight_builtins") + runtime! syntax/prog8_builtins.vim +endif + + syn region prog8Asm start="\(%asm\)\@16<=\s\+{{" end="}}" contains= \prog8Comment, \prog8Character, \prog8Number, \prog8AsmIdentifier, \prog8AsmStatement, - \prog8AsmLabel + \prog8AsmLabel, + \prog8BuiltInVar, + \prog8BuiltInFunc +syn sync match prog8AsmSync groupthere prog8Asm "%asm\s\+{{" syn keyword prog8AsmIdentifier a x y contained diff --git a/syntax-files/Vim/prog8_builtins.vim b/syntax-files/Vim/prog8_builtins.vim new file mode 100644 index 000000000..d737d5a75 --- /dev/null +++ b/syntax-files/Vim/prog8_builtins.vim @@ -0,0 +1,820 @@ +" Vim syntax file +" Language: Prog8 (built-in functions) +" Maintainer: Elektron72 +" Latest Revision: 23 March 2021 + + +" Built-in functions + +" Math functions +syn keyword prog8BuiltInFunc abs atan ceil cos cos8u cos8 cos16u cos16 deg floor +syn keyword prog8BuiltInFunc ln log2 rad round sin sgn sin8u sin8 sin16u sin16 +syn keyword prog8BuiltInFunc sqrt16 sqrt tan + +" Array functions +syn keyword prog8BuiltInFunc any all len max min reverse sum sort + +" Miscellaneous functions +syn keyword prog8BuiltInFunc cmp lsb msb mkword peek peekw poke pokew rnd rndw +syn keyword prog8BuiltInFunc rndf fastrnd8 rol rol2 ror ror2 sizeof offsetof +syn keyword prog8BuiltInFunc swap memory + + +" c64/floats.p8 +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" + + +" c64/graphics.p8 +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" + + +" c64/syslib.p8 +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" + + +" c64/textio.p8 +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" + + +" cx16/floats.p8 +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" + + +" cx16/gfx2.p8 +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" + + +" cx16/graphics.p8 +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" + + +" cx16/palette.p8 +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" + +" cx16/syslib.p8 +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" + + +" cx16/textio.p8 +syn match prog8BuiltInVar "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInVar "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" + + +" conv.p8 +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" + + +" cx16logo.p8 +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInVar "\" + + +" diskio.p8 +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" + + +" prog8_lib.p8 +syn match prog8BuiltInFunc "\" + + +" string.p8 +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" +syn match prog8BuiltInFunc "\" + + +" test_stack.p8 +syn match prog8BuiltInFunc "\" + + +hi def link prog8BuiltInVar Identifier +hi def link prog8BuiltInFunc Function diff --git a/syntax-files/Vim/readme.txt b/syntax-files/Vim/readme.txt index 419d61f55..f405a3e18 100644 --- a/syntax-files/Vim/readme.txt +++ b/syntax-files/Vim/readme.txt @@ -3,7 +3,9 @@ Created by Elektron72 on github To install: - Copy prog8.vim into ~/.vim/syntax/ + Copy prog8.vim and prog8_builtins.vim into ~/.vim/syntax/. If you will never + use highlighting for built-in functions and variables, you do not need to + copy prog8_builtins.vim. To enable: Type: @@ -12,3 +14,9 @@ To enable: like to enable syntax highlighting for all .p8 files, add the following line to your .vimrc: au BufRead,BufNewFile *.p8 setfiletype prog8 + + If you would like to disable highlighting for built-in functions and + variables without deleting or renaming the file, add the following line to + your .vimrc: + let g:prog8_no_highlight_builtins = 1 + (The value doesn't actually matter, only that the variable is defined.)