X-Git-Url: http://nitlanguage.org diff --git a/misc/vim/syntax/nit.vim b/misc/vim/syntax/nit.vim index 4690189..8ad3f26 100644 --- a/misc/vim/syntax/nit.vim +++ b/misc/vim/syntax/nit.vim @@ -47,6 +47,7 @@ syn match NITClosure "!\h\w*" " Fallback highlight keywords syn match NITNull "\<\(null\)\>" syn match NITControl "\<\(init\|end\|not null\|not\|var\|do\|then\|else\|loop\)\>" +syn match NITKeyword "\<\(super\)\>" " Unmatchning error syn match Error "\" @@ -57,6 +58,7 @@ syn region NITFunctionDecl matchgroup=NITDefine start="\\s*" matchgroup=NO syn region NITTypeDecl matchgroup=NITDefine start="\\s*" matchgroup=NONE end="\ze\(\\|\s\|:\|(\|$\)" oneline contained containedin=NITClassBlock syn region NITAttrDecl matchgroup=NITDefine start="\\s*\ze_" matchgroup=NONE end="\ze\(\\|\s\|:\|(\|$\)" oneline contained containedin=NITClassBlock syn region NITInitDecl matchgroup=NITDefine start="\\s*" matchgroup=NONE end="\ze\(\\|\s\|:\|(\|$\)" oneline contained containedin=NITClassBlock +syn match NITDefine "\<\(super\)\ze\s\+[A-Z]" contained containedin=NITClassBlock syn region NITStmtBlock matchgroup=NITControl start="\<\(do\|then\|else\|loop\)\>\ze\s*\(#\|$\)" matchgroup=NITControl end="^\s*\<\(end\|\zeelse\|\ze!\)\>" contains=ALLBUT,NITTypeDecl,NITAttrDecl,NITInitDecl syn region NITStmtBlock matchgroup=NITControl start="\<\(do\|then\|else\|loop\)\>" matchgroup=NITControl end="\" oneline @@ -71,7 +73,7 @@ syn match NITSharpBang "\%^#!.*" syn match NITComment "#.*" contains=NITTodo " Keywords -syn keyword NITKeyword is abstract intern extern super new +syn keyword NITKeyword is abstract intern extern new syn keyword NITDefine private public protected intrude readable writable redef syn keyword NITControl if while for assert and or in as isa once break continue return abort syn keyword NITClass nullable