aboutsummaryrefslogtreecommitdiff
path: root/runtime/syntax/wml.vim
diff options
context:
space:
mode:
authorZyX <kp-pav@yandex.ru>2017-12-03 16:49:30 +0300
committerZyX <kp-pav@yandex.ru>2017-12-03 16:49:30 +0300
commitc49e22d3964d6c7ae1c24e8ad01b5fec4ca40b57 (patch)
treeb7e59c416d1435725c65f8952b6e55c70544d97e /runtime/syntax/wml.vim
parent62108c3b0be46936c83f6d4c98b44ceb5e6f77fd (diff)
parent27a577586eace687c47e7398845178208cae524a (diff)
downloadrneovim-c49e22d3964d6c7ae1c24e8ad01b5fec4ca40b57.tar.gz
rneovim-c49e22d3964d6c7ae1c24e8ad01b5fec4ca40b57.tar.bz2
rneovim-c49e22d3964d6c7ae1c24e8ad01b5fec4ca40b57.zip
Merge branch 'master' into s-dash-stdin
Diffstat (limited to 'runtime/syntax/wml.vim')
-rw-r--r--runtime/syntax/wml.vim64
1 files changed, 21 insertions, 43 deletions
diff --git a/runtime/syntax/wml.vim b/runtime/syntax/wml.vim
index 5957930c8e..73bf822e40 100644
--- a/runtime/syntax/wml.vim
+++ b/runtime/syntax/wml.vim
@@ -16,21 +16,14 @@
" vim-package around your corner :)
-" For version 5.x: Clear all syntax items
-" For version 6.x: Quit when a syntax file was already loaded
-if version < 600
- syn clear
-elseif exists("b:current_syntax")
+" quit when a syntax file was already loaded
+if exists("b:current_syntax")
finish
endif
" A lot of the web stuff looks like HTML so we load that first
-if version < 600
- so <sfile>:p:h/html.vim
-else
- runtime! syntax/html.vim
-endif
+runtime! syntax/html.vim
unlet b:current_syntax
if !exists("main_syntax")
@@ -108,11 +101,7 @@ syn region htmlTagName start="\<\(define-tag\|define-region\)" end="\>" cont
" The perl include stuff
if main_syntax != 'perl'
" Perl script
- if version < 600
- syn include @wmlPerlScript <sfile>:p:h/perl.vim
- else
- syn include @wmlPerlScript syntax/perl.vim
- endif
+ syn include @wmlPerlScript syntax/perl.vim
unlet b:current_syntax
syn region perlScript start=+<perl>+ keepend end=+</perl>+ contains=@wmlPerlScript,wmlPerlTag
@@ -140,33 +129,22 @@ if main_syntax == "html"
endif
" Define the default highlighting.
-" For version 5.7 and earlier: only when not done already
-" For version 5.8 and later: only when an item doesn't have highlighting yet
-if version >= 508 || !exists("did_wml_syn_inits")
- let did_wml_syn_inits = 1
- if version < 508
- let did_wml_syn_inits = 1
- command -nargs=+ HiLink hi link <args>
- else
- command -nargs=+ HiLink hi def link <args>
- endif
-
- HiLink wmlNextLine Special
- HiLink wmlUse Include
- HiLink wmlUsed String
- HiLink wmlBody Special
- HiLink wmlDiverted Label
- HiLink wmlDivert Delimiter
- HiLink wmlDivertEnd Delimiter
- HiLink wmlLocationId Label
- HiLink wmlLocation Delimiter
-" HiLink wmlLocationed Delimiter
- HiLink wmlDefineName String
- HiLink wmlComment Comment
- HiLink wmlInclude Include
- HiLink wmlSharpBang PreProc
-
- delcommand HiLink
-endif
+" Only when an item doesn't have highlighting yet
+
+hi def link wmlNextLine Special
+hi def link wmlUse Include
+hi def link wmlUsed String
+hi def link wmlBody Special
+hi def link wmlDiverted Label
+hi def link wmlDivert Delimiter
+hi def link wmlDivertEnd Delimiter
+hi def link wmlLocationId Label
+hi def link wmlLocation Delimiter
+" hi def link wmlLocationed Delimiter
+hi def link wmlDefineName String
+hi def link wmlComment Comment
+hi def link wmlInclude Include
+hi def link wmlSharpBang PreProc
+
let b:current_syntax = "wml"