aboutsummaryrefslogtreecommitdiff
path: root/runtime/syntax/asm68k.vim
diff options
context:
space:
mode:
Diffstat (limited to 'runtime/syntax/asm68k.vim')
-rw-r--r--runtime/syntax/asm68k.vim111
1 files changed, 49 insertions, 62 deletions
diff --git a/runtime/syntax/asm68k.vim b/runtime/syntax/asm68k.vim
index cd23517cad..1607507909 100644
--- a/runtime/syntax/asm68k.vim
+++ b/runtime/syntax/asm68k.vim
@@ -8,11 +8,8 @@
" Feel free to contribute...
"
-" For version 5.x: Clear all syntax items
-" For version 6.x: Quit when a syntax file was already loaded
-if version < 600
- syntax clear
-elseif exists("b:current_syntax")
+" quit when a syntax file was already loaded
+if exists("b:current_syntax")
finish
endif
@@ -328,63 +325,53 @@ syn match asm68kDirective "\<XREF\(\.S\)\=\s"
syn case match
" 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_asm68k_syntax_inits")
- if version < 508
- let did_asm68k_syntax_inits = 1
- command -nargs=+ HiLink hi link <args>
- else
- command -nargs=+ HiLink hi def link <args>
- endif
-
- " The default methods for highlighting. Can be overridden later
- " Comment Constant Error Identifier PreProc Special Statement Todo Type
- "
- " Constant Boolean Character Number String
- " Identifier Function
- " PreProc Define Include Macro PreCondit
- " Special Debug Delimiter SpecialChar SpecialComment Tag
- " Statement Conditional Exception Keyword Label Operator Repeat
- " Type StorageClass Structure Typedef
-
- HiLink asm68kComment Comment
- HiLink asm68kTodo Todo
-
- HiLink hexNumber Number " Constant
- HiLink octNumber Number " Constant
- HiLink binNumber Number " Constant
- HiLink decNumber Number " Constant
- HiLink floatNumber Number " Constant
- HiLink floatExponent Number " Constant
- HiLink floatE SpecialChar " Statement
- "HiLink floatE Number " Constant
-
- HiLink asm68kImmediate SpecialChar " Statement
- "HiLink asm68kSymbol Constant
-
- HiLink asm68kString String " Constant
- HiLink asm68kCharError Error
- HiLink asm68kStringError Error
-
- HiLink asm68kReg Identifier
- HiLink asm68kOperator Identifier
-
- HiLink asm68kInclude Include " PreProc
- HiLink asm68kMacro Macro " PreProc
- HiLink asm68kMacroParam Keyword " Statement
-
- HiLink asm68kDirective Special
- HiLink asm68kPreCond Special
-
-
- HiLink asm68kOpcode Statement
- HiLink asm68kCond Conditional " Statement
- HiLink asm68kRepeat Repeat " Statement
-
- HiLink asm68kLabel Type
- delcommand HiLink
-endif
+" Only when an item doesn't have highlighting yet
+
+" The default methods for highlighting. Can be overridden later
+" Comment Constant Error Identifier PreProc Special Statement Todo Type
+"
+" Constant Boolean Character Number String
+" Identifier Function
+" PreProc Define Include Macro PreCondit
+" Special Debug Delimiter SpecialChar SpecialComment Tag
+" Statement Conditional Exception Keyword Label Operator Repeat
+" Type StorageClass Structure Typedef
+
+hi def link asm68kComment Comment
+hi def link asm68kTodo Todo
+
+hi def link hexNumber Number " Constant
+hi def link octNumber Number " Constant
+hi def link binNumber Number " Constant
+hi def link decNumber Number " Constant
+hi def link floatNumber Number " Constant
+hi def link floatExponent Number " Constant
+hi def link floatE SpecialChar " Statement
+"hi def link floatE Number " Constant
+
+hi def link asm68kImmediate SpecialChar " Statement
+"hi def link asm68kSymbol Constant
+
+hi def link asm68kString String " Constant
+hi def link asm68kCharError Error
+hi def link asm68kStringError Error
+
+hi def link asm68kReg Identifier
+hi def link asm68kOperator Identifier
+
+hi def link asm68kInclude Include " PreProc
+hi def link asm68kMacro Macro " PreProc
+hi def link asm68kMacroParam Keyword " Statement
+
+hi def link asm68kDirective Special
+hi def link asm68kPreCond Special
+
+
+hi def link asm68kOpcode Statement
+hi def link asm68kCond Conditional " Statement
+hi def link asm68kRepeat Repeat " Statement
+
+hi def link asm68kLabel Type
let b:current_syntax = "asm68k"