• R/O
  • HTTP
  • SSH
  • HTTPS

kink.vim: Commit

Vim Plugins for Kink Programming Language


Commit MetaInfo

Revision23fda2dc41bf3a5db3edbce1ce24881c734117fd (tree)
Time2017-04-10 00:43:45
AuthorMiyakawa Taku <miyakawa.taku@gmai...>
CommiterMiyakawa Taku

Log Message

improve syntax highlighting for identifiers

Change Summary

Incremental Difference

--- a/syntax/kink.vim
+++ b/syntax/kink.vim
@@ -1,7 +1,7 @@
11 " Vim syntax file
22 " Language: Kink (http://code.google.com/p/kink-lang/)
33 " Maintainer: Miyakawa Taku <miyakawa.taku@gmail.com>
4-" Last Change: 2016-12-29
4+" Last Change: 2017-04-10
55
66 " Copyright (c) 2013- Miyakawa Taku
77 "
@@ -31,8 +31,13 @@ endif
3131 let s:save_cpo = &cpo
3232 set cpo&vim
3333
34-syntax match kinkVerb "[a-z_][a-zA-Z_0-9?]*"
35-syntax match kinkNoun "[A-Z][a-zA-Z_0-9?]*"
34+syntax match kinkVerbRef "::\?[a-z_][a-zA-Z_0-9?]*"
35+syntax match kinkVerbDeref "\$\$\?[a-z_][a-zA-Z_0-9?]*"
36+syntax match kinkVerbCall "[a-z_][a-zA-Z_0-9?]*"
37+
38+syntax match kinkNounRef "::\?[A-Z][a-zA-Z_0-9?]*"
39+syntax match kinkNounDeref "[A-Z][a-zA-Z_0-9?]*"
40+
3641 syntax keyword kinkTodo contained TODO FIXME XXX
3742 syntax match kinkComment "#.*" contains=kinkTodo
3843 syntax region kinkString start=+'+ skip=+''+ end=+'+
@@ -44,7 +49,10 @@ syntax match kinkInteger "0x[0-9a-f_]*\|0b[01_]*\|[0-9][0-9_]*"
4449 syntax match kinkDecimal "[0-9][0-9_]*\.[0-9][0-9_]*"
4550
4651 " Define the default highlighting.
47-highlight default link kinkNoun Identifier
52+highlight default link kinkVerbRef Identifier
53+highlight default link kinkVerbDeref Identifier
54+highlight default link kinkNounRef Identifier
55+highlight default link kinkNounDeref Identifier
4856 highlight default link kinkComment Comment
4957 highlight default link kinkTodo Todo
5058 highlight default link kinkString String
Show on old repository browser