initial commit
This commit is contained in:
commit
9da7211cb4
1
ftdetect/hb.vim
Normal file
1
ftdetect/hb.vim
Normal file
|
@ -0,0 +1 @@
|
|||
autocmd BufNewFile,BufRead *.hb setfiletype hblang
|
1
ftdetect/hblang.vim
Normal file
1
ftdetect/hblang.vim
Normal file
|
@ -0,0 +1 @@
|
|||
autocmd BufNewFile,BufRead *.hb setfiletype hblang
|
2
ftplugin/hb.vim
Normal file
2
ftplugin/hb.vim
Normal file
|
@ -0,0 +1,2 @@
|
|||
setlocal commentstring=//\ %s
|
||||
|
1
ftplugin/hblang.vim
Normal file
1
ftplugin/hblang.vim
Normal file
|
@ -0,0 +1 @@
|
|||
setlocal commentstring=//\ %s
|
0
indent/hblang.vim
Normal file
0
indent/hblang.vim
Normal file
38
syntax/hblang.vim
Normal file
38
syntax/hblang.vim
Normal file
|
@ -0,0 +1,38 @@
|
|||
syntax keyword hblangKeywords
|
||||
\ if
|
||||
\ loop
|
||||
\ fn
|
||||
\ return
|
||||
\ else
|
||||
\ break
|
||||
\ continue
|
||||
\ struct
|
||||
|
||||
syntax match hblangNumber "\v<\d+>"
|
||||
syntax match hblangNumber "\v<0x\x+([Pp]-?)?\x+>"
|
||||
syntax match hblangNumber "\v<0b[01]+>"
|
||||
syntax match hblangNumber "\v<0o\o+>"
|
||||
|
||||
syntax keyword hblangBoolean true false
|
||||
|
||||
syntax match hblangDirective /@\<\a\+\>/
|
||||
syntax match hblangFunction /[a-zA-Z_]\+\ze(/
|
||||
|
||||
|
||||
syntax region hblangString start=/"/ skip=/\\"/ end=/"/ oneline
|
||||
syntax region hblangComment start=/\/\// end=/\n/ oneline
|
||||
|
||||
|
||||
highlight default link hblangComment Comment
|
||||
|
||||
highlight default link hblangString String
|
||||
highlight default link hblangNumber Number
|
||||
highlight default link hblangBoolean Boolean
|
||||
|
||||
highlight default link hblangOperator Operator
|
||||
highlight default link hblangKeywords Keyword
|
||||
highlight default link hblangAttributes PreProc
|
||||
highlight default link hblangStructure Structure
|
||||
highlight default link hblangType Type
|
||||
highlight default link hblangFunction Function
|
||||
highlight default link hblangDirective PreProc
|
Loading…
Reference in a new issue