summaryrefslogtreecommitdiffstats
path: root/runtime/syntax/c.vim
diff options
context:
space:
mode:
Diffstat (limited to 'runtime/syntax/c.vim')
-rw-r--r--runtime/syntax/c.vim12
1 files changed, 11 insertions, 1 deletions
diff --git a/runtime/syntax/c.vim b/runtime/syntax/c.vim
index 5ed8fdc..30db943 100644
--- a/runtime/syntax/c.vim
+++ b/runtime/syntax/c.vim
@@ -252,7 +252,7 @@ if exists("c_gnu")
syn keyword cOperator typeof __typeof__
syn keyword cOperator __real__ __imag__
syn keyword cStorageClass __attribute__ __const__ __extension__
- syn keyword cStorageClass inline __inline__
+ syn keyword cStorageClass inline __inline __inline__
syn keyword cStorageClass __restrict__ __volatile__ __noreturn__
endif
syn keyword cType int long short char void
@@ -444,6 +444,14 @@ syn match cUserLabel display "\I\i*" contained
syn match cBitField display "^\s*\zs\I\i*\s*:\s*[1-9]"me=e-1 contains=cType
syn match cBitField display ";\s*\zs\I\i*\s*:\s*[1-9]"me=e-1 contains=cType
+if exists("c_functions")
+ syn match cFunction "\<\h\w*\ze\_s*("
+ endif
+
+if exists("c_function_pointers")
+ syn match cFunctionPointer "\%((\s*\*\s*\)\@<=\h\w*\ze\s*)\_s*(.*)"
+endif
+
if exists("c_minlines")
let b:c_minlines = c_minlines
else
@@ -513,6 +521,8 @@ hi def link cCppOutSkip cCppOutIf2
hi def link cCppInElse2 cCppOutIf2
hi def link cCppOutIf2 cCppOut
hi def link cCppOut Comment
+hi def link cFunction Function
+hi def link cFunctionPointer Function
let b:current_syntax = "c"