robin/laufey
git clone https://git.robinwobin.dev/robin/laufey
aa1d8a2702
master
1" Vim syntax file 2" Language: C 3" Maintainer: The Vim Project <https://github.com/vim/vim> 4" Last Change: 2026 Sep 21 5" Former Maintainer: Bram Moolenaar <Bram@vim.org> 6 7" Quit when a (custom) syntax file was already loaded 8if exists ( "b:current_syntax" ) 9finish 10endif 11 12let s: cpo_save = & cpo 13set cpo & vim 14 15let s: ft = matchstr ( & ft , '^\%([^.]\)\+' ) 16 17" check if this was included from cpp.vim 18let s: in_cpp_family = exists ( "b:filetype_in_cpp_family" ) 19 20" Optional embedded Autodoc parsing 21" To enable it add: let g:c_autodoc = 1 22" to your .vimrc 23if exists ( "c_autodoc" ) 24syn include @cAutodoc <sfile>:p:h/autodoc.vim 25unlet b: current_syntax 26endif 27 28" In VMS C keywords contain '$' characters. 29if has ( "vms" ) 30syn iskeyword @,48-57,_,192-255,$ 31else 32syn iskeyword @,48-57,_,192-255 33endif 34 35" A bunch of useful C keywords 36syn keyword cStatement goto break return continue asm 37syn keyword cLabel case default 38syn keyword cConditional if else switch 39syn keyword cRepeat while for do 40 41syn keyword cTodo contained TODO FIXME XXX 42 43" It's easy to accidentally add a space after a backslash that was intended 44" for line continuation. Some compilers allow it, which makes it 45" unpredictable and should be avoided. 46syn match cBadContinuation contained "\\\s\+$ " 47 48" cCommentGroup allows adding matches for special things in comments 49syn cluster cCommentGroup contains = cTodo , cBadContinuation 50 51" String and Character constants 52" Highlight special characters (those which have a backslash) differently 53syn match cSpecial display contained "\\\%(x\x\+\|\o\{1,3}\|.\|$\) " 54if ! exists ( "c_no_utf" ) 55syn match cSpecial display contained "\\\%(u\x\{4}\|U\x\{8}\) " 56endif 57 58if ! exists ( "c_no_cformat" ) 59" Highlight % items in strings. 60if ! exists ( "c_no_c99" ) " ISO C99 61syn match cFormat display "%\%(\d\+\$\)\= [ -+' #0* ] * \%(\d * \|\*\|\*\d\+\$\)\%(\.\%(\d * \|\*\|\*\d\+\$\)\)\=\%( [ hlLjzt ] \|ll\|hh\)\=\%( [ aAbdiuoxXDOUfFeEgGcCsSpn ] \|\[\^\=. [ ^ ] ] * \]\) "contained 62else 63syn match cFormat display "%\%(\d\+\$\)\= [ -+' #0* ] * \%(\d * \|\*\|\*\d\+\$\)\%(\.\%(\d * \|\*\|\*\d\+\$\)\)\=\%( [ hlL ] \|ll\)\=\%( [ bdiuoxXDOUfeEgGcCsSpn ] \|\[\^\=. [ ^ ] ] * \]\) "contained 64endif 65syn match cFormat display "%% "contained 66endif 67 68" cCppString: same as cString, but ends at end of line 69if s: in_cpp_family && ! exists ( "cpp_no_cpp11" ) && ! exists ( "c_no_cformat" ) 70" ISO C++11 71syn region cString start = +\%(L\|u\|u8\|U\|R\|LR\|u8R\|uR\|UR\)\=" +skip = +\\\\\|\\" +end = +" +contains = cSpecial , cFormat , @Spell extend 72syn region cCppString start = +\%(L\|u\|u8\|U\|R\|LR\|u8R\|uR\|UR\)\=" +skip = +\\\\\|\\"\|\\$ +excludenl end = +" +end = '$ 'contains = cSpecial , cFormat , @Spell 73elseif s: ft ==# "c" && ! exists ( "c_no_c11" ) && ! exists ( "c_no_cformat" ) 74" ISO C99 75syn region cString start = +\%(L\|U\|u8\)\=" +skip = +\\\\\|\\" +end = +" +contains = cSpecial , cFormat , @Spell extend 76syn region cCppString start = +\%(L\|U\|u8\)\=" +skip = +\\\\\|\\"\|\\$ +excludenl end = +" +end = '$ 'contains = cSpecial , cFormat , @Spell 77else 78" older C or C++ 79syn match cFormat display "%% "contained 80syn region cString start = +L\=" +skip = +\\\\\|\\" +end = +" +contains = cSpecial , cFormat , @Spell extend 81syn region cCppString start = +L\=" +skip = +\\\\\|\\"\|\\$ +excludenl end = +" +end = '$ 'contains = cSpecial , cFormat , @Spell 82endif 83 84syn region cCppSkip contained start = "^\s * \%(%:\|#\)\s * \%(if\>\|ifdef\>\|ifndef\>\) "skip = "\\$ "end = "^\s * \%(%:\|#\)\s * endif\> "contains = cSpaceError , cCppSkip 85 86syn cluster cStringGroup contains = cCppString , cCppSkip 87 88syn match cCharacter "L\=' [ ^\\ ] ' " 89syn match cCharacter "L' [ ^' ] * ' "contains = cSpecial 90if exists ( "c_gnu" ) 91syn match cSpecialError "L\='\\ [ ^'\"?\\abefnrtv ] ' " 92syn match cSpecialCharacter "L\='\\ [ '\"?\\abefnrtv ] ' " 93else 94syn match cSpecialError "L\='\\ [ ^'\"?\\abfnrtv ] ' " 95syn match cSpecialCharacter "L\='\\ [ '\"?\\abfnrtv ] ' " 96endif 97syn match cSpecialCharacter display "L\='\\\o\{1,3}' " 98syn match cSpecialCharacter display "'\\x\x\{1,2}' " 99syn match cSpecialCharacter display "L'\\x\x\+' " 100 101if ( s: ft ==# "c" && ! exists ( "c_no_c11" )) || ( s: in_cpp_family && ! exists ( "cpp_no_cpp11" )) 102" ISO C11 or ISO C++ 11 103if exists ( "c_no_cformat" ) 104syn region cString start = +\%(U\|u8\=\)" +skip = +\\\\\|\\" +end = +" +contains = cSpecial , @Spell extend 105else 106syn region cString start = +\%(U\|u8\=\)" +skip = +\\\\\|\\" +end = +" +contains = cSpecial , cFormat , @Spell extend 107endif 108syn match cCharacter "[ Uu ] ' [ ^\\ ] ' " 109syn match cCharacter "[ Uu ] ' [ ^' ] * ' "contains = cSpecial 110if exists ( "c_gnu" ) 111syn match cSpecialError "[ Uu ] '\\ [ ^'\"?\\abefnrtv ] ' " 112syn match cSpecialCharacter "[ Uu ] '\\ [ '\"?\\abefnrtv ] ' " 113else 114syn match cSpecialError "[ Uu ] '\\ [ ^'\"?\\abfnrtv ] ' " 115syn match cSpecialCharacter "[ Uu ] '\\ [ '\"?\\abfnrtv ] ' " 116endif 117syn match cSpecialCharacter display "[ Uu ] '\\\o\{1,3}' " 118syn match cSpecialCharacter display "[ Uu ] '\\x\x\+' " 119endif 120 121if ( s: ft ==# "c" && ! exists ( "c_no_c23" )) || ( s: in_cpp_family && ! exists ( "cpp_no_cpp17" )) 122syn match cCharacter "u8' [ ^\\ ] ' " 123syn match cCharacter "u8' [ ^' ] * ' "contains = cSpecial 124if exists ( "c_gnu" ) 125syn match cSpecialError "u8'\\ [ ^'\"?\\abefnrtv ] ' " 126syn match cSpecialCharacter "u8'\\ [ '\"?\\abefnrtv ] ' " 127else 128syn match cSpecialError "u8'\\ [ ^'\"?\\abfnrtv ] ' " 129syn match cSpecialCharacter "u8'\\ [ '\"?\\abfnrtv ] ' " 130endif 131syn match cSpecialCharacter display "u8'\\\o\{1,3}' " 132syn match cSpecialCharacter display "u8'\\x\x\+' " 133endif 134 135"when wanted, highlight trailing white space 136if exists ( "c_space_errors" ) 137if ! exists ( "c_no_trail_space_error" ) 138syn match cSpaceError display excludenl "\s\+$ " 139endif 140if ! exists ( "c_no_tab_space_error" ) 141syn match cSpaceError display "\+\t "me= e-1 142endif 143endif 144 145" This should be before cErrInParen to avoid problems with #define ({ xxx }) 146if exists ( "c_curly_error" ) 147syn match cCurlyError "} " 148syn region cBlock start = "{ "end = "} "contains = ALLBUT , cBadBlock , cCurlyError , cInitBlock , @cParenGroup , cErrInParen , cCppParen , cErrInBracket , cCppBracket , @cStringGroup , @Spell fold 149else 150syn region cBlock start = "{ "end = "} "transparent fold 151endif 152 153" Catch errors caused by wrong parenthesis and brackets. 154" Also accept <% for {, %> for }, <: for [ and :> for ] (C99) 155" But avoid matching <::. 156syn cluster cParenGroup contains = cParenError , cIncluded , cSpecial , cCommentSkip , cCommentString , cComment2String , @cCommentGroup , cCommentStartError , cUserLabel , cBitField , cOctalZero , @cCppOutInGroup , cFormat , cNumber , cFloat , cOctal , cOctalError , cNumbersCom , cBadParenBlock 157if exists ( "c_no_curly_error" ) 158if s: in_cpp_family && ! exists ( "cpp_no_cpp11" ) 159syn region cParen transparent start = '( 'end = ') 'contains = ALLBUT , @cParenGroup , cCppParen , @cStringGroup , @Spell 160" cCppParen: same as cParen but ends at end-of-line; used in cDefine 161syn region cCppParen transparent start = '( 'skip = '\\$ 'excludenl end = ') 'end = '$ 'contained contains = ALLBUT , @cParenGroup , cParen , cString , @Spell 162syn match cParenError display ") " 163syn match cErrInParen display contained "^^<%\|^%> " 164else 165syn region cParen transparent start = '( 'end = ') 'contains = ALLBUT , cBlock , @cParenGroup , cCppParen , @cStringGroup , @Spell 166" cCppParen: same as cParen but ends at end-of-line; used in cDefine 167syn region cCppParen transparent start = '( 'skip = '\\$ 'excludenl end = ') 'end = '$ 'contained contains = ALLBUT , @cParenGroup , cParen , cString , @Spell 168syn match cParenError display ") " 169syn match cErrInParen display contained "^ [ {} ] \|^<%\|^%> " 170endif 171elseif exists ( "c_no_bracket_error" ) 172if s: in_cpp_family && ! exists ( "cpp_no_cpp11" ) 173syn region cParen transparent start = '( 'end = ') 'contains = ALLBUT , @cParenGroup , cCppParen , @cStringGroup , @Spell 174" cCppParen: same as cParen but ends at end-of-line; used in cDefine 175syn region cCppParen transparent start = '( 'skip = '\\$ 'excludenl end = ') 'end = '$ 'contained contains = ALLBUT , @cParenGroup , cParen , cString , @Spell 176syn match cParenError display ") " 177syn match cErrInParen display contained "<%\|%> " 178else 179syn region cParen transparent start = '( 'end = ') 'end = '} 'me= s-1contains = ALLBUT , cBlock , @cParenGroup , cCppParen , @cStringGroup , @Spell 180" cCppParen: same as cParen but ends at end-of-line; used in cDefine 181syn region cCppParen transparent start = '( 'skip = '\\$ 'excludenl end = ') 'end = '$ 'contained contains = ALLBUT , @cParenGroup , cParen , cString , @Spell 182syn match cParenError display ") " 183syn match cErrInParen display contained "[ {} ] \|<%\|%> " 184endif 185else 186if s: in_cpp_family && ! exists ( "cpp_no_cpp11" ) 187syn region cParen transparent start = '( 'end = ') 'contains = ALLBUT , @cParenGroup , cCppParen , cErrInBracket , cCppBracket , @cStringGroup , @Spell 188" cCppParen: same as cParen but ends at end-of-line; used in cDefine 189syn region cCppParen transparent start = '( 'skip = '\\$ 'excludenl end = ') 'end = '$ 'contained contains = ALLBUT , @cParenGroup , cErrInBracket , cParen , cBracket , cString , @Spell 190syn match cParenError display "[ \]) ] " 191syn match cErrInParen display contained "<%\|%> " 192syn region cBracket transparent start = '\[\|<::\@! 'end = ']\|:> 'contains = ALLBUT , @cParenGroup , cErrInParen , cCppParen , cCppBracket , @cStringGroup , @Spell 193else 194syn region cParen transparent start = '( 'end = ') 'end = '} 'me= s-1contains = ALLBUT , cBlock , @cParenGroup , cCppParen , cErrInBracket , cCppBracket , @cStringGroup , @Spell 195" cCppParen: same as cParen but ends at end-of-line; used in cDefine 196syn region cCppParen transparent start = '( 'skip = '\\$ 'excludenl end = ') 'end = '$ 'contained contains = ALLBUT , @cParenGroup , cErrInBracket , cParen , cBracket , cString , @Spell 197syn match cParenError display "[ \]) ] " 198syn match cErrInParen display contained "[ \]{} ] \|<%\|%> " 199syn region cBracket transparent start = '\[\|<::\@! 'end = ']\|:> 'end = '} 'me= s-1contains = ALLBUT , cBlock , @cParenGroup , cErrInParen , cCppParen , cCppBracket , @cStringGroup , @Spell 200endif 201" cCppBracket: same as cParen but ends at end-of-line; used in cDefine 202syn region cCppBracket transparent start = '\[\|<::\@! 'skip = '\\$ 'excludenl end = ']\|:> 'end = '$ 'contained contains = ALLBUT , @cParenGroup , cErrInParen , cParen , cBracket , cString , @Spell 203syn match cErrInBracket display contained "[ );{} ] \|<%\|%> " 204endif 205 206if s: ft ==# 'c' || exists ( "cpp_no_cpp11" ) 207syn region cBadBlock keepend start = "{ "end = "} "contained containedin = cParen , cBracket , cBadBlock transparent fold 208if ! exists ( "c_no_curly_error" ) && ! exists ( "c_no_bracket_error" ) 209" Do not mistake an unmatched ')' followed by a block for a compound literal. 210syn region cBadParenBlock keepend transparent start = ')\_s * \ze\%({\|<%\) 'matchgroup = cErrInBracket end = '}\|%> 'contained containedin = cBracket , cBadBlock contains = ALLBUT , cBlock , cBadBlock , cInitBlock , @cParenGroup , cErrInParen , cCppParen , cCppBracket , @cStringGroup , @Spell 211endif 212endif 213 214" Compound literals and initializers may appear inside parentheses or brackets. 215syn region cInitBlock transparent matchgroup = cInitBlock start = '\%( [ )= ] \_s * \)\@<=\%({\|<%\) 'end = '}\|%> 'contained containedin = cParen , cBracket , cBadBlock contains = ALLBUT , cBlock , cCurlyError , @cParenGroup , cErrInParen , cCppParen , cErrInBracket , cCppBracket , @cStringGroup , @Spell , cInitBlock fold 216 217"integer number, or floating point number without a dot and with "f". 218syn case ignore 219syn match cNumbers display transparent "\<\d\|\.\d "contains = cNumber , cFloat , cOctalError , cOctal 220" Same, but without octal error (for comments) 221syn match cNumbersCom display contained transparent "\<\d\|\.\d "contains = cNumber , cFloat , cOctal 222 223" cpp.vim handles these 224if ! exists ( "c_no_c23" ) && ! s: in_cpp_family 225syn match cNumber display contained "\d\+\%('\d\+\) * \%(u\=l\{0,2}\|ll\=u\|u\=wb\|wbu\=\)\> " 226"hex number 227syn match cNumber display contained "0x\x\+\%('\x\+\) * \%(u\=l\{0,2}\|ll\=u\|u\=wb\|wbu\=\)\> " 228" Flag the first zero of an octal number as something special 229syn match cOctal display contained "0\o * \%('\o\+\) * \%(u\=l\{0,2}\|ll\=u\|u\=wb\|wbu\=\)\> "contains = cOctalZero 230"binary number 231syn match cNumber display contained "0b [ 01 ] \+\%(' [ 01 ] \+\) * \%(u\=l\{0,2}\|ll\=u\|u\=wb\|wbu\=\)\> " 232else 233syn match cNumber display contained "\d\+\%(u\=l\{0,2}\|ll\=u\)\> " 234"hex number 235syn match cNumber display contained "0x\x\+\%(u\=l\{0,2}\|ll\=u\)\> " 236" Flag the first zero of an octal number as something special 237syn match cOctal display contained "0\o\+\%(u\=l\{0,2}\|ll\=u\)\> "contains = cOctalZero 238syn match cOctalZero display contained "\<0 " 239endif 240 241if ! exists ( "c_no_c29" ) && ! s: in_cpp_family 242" XXX: 0-prefixed octal literals e.g. 0123 are obsolescent since C29 243syn match cOctal display contained "0 [ Oo ] \o\+\%('\o\+\) * \%(u\=l\{0,2}\|ll\=u\|u\=wb\|wbu\=\)\> " 244endif 245 246"floating point number, with dot, optional exponent 247syn match cFloat display contained "\d\+\.\d * \%(e [ -+ ] \=\d\+\)\= [ fl ] \= " 248"floating point number, starting with a dot, optional exponent 249syn match cFloat display contained "\.\d\+\%(e [ -+ ] \=\d\+\)\= [ fl ] \=\> " 250"floating point number, without dot, with exponent 251syn match cFloat display contained "\d\+e [ -+ ] \=\d\+ [ fl ] \=\> " 252if ! exists ( "c_no_c99" ) 253"hexadecimal floating point number, optional leading digits, with dot, with exponent 254syn match cFloat display contained "0x\x * \.\x\+p [ -+ ] \=\d\+ [ fl ] \=\> " 255"hexadecimal floating point number, with leading digits, optional dot, with exponent 256syn match cFloat display contained "0x\x\+\.\=p [ -+ ] \=\d\+ [ fl ] \=\> " 257endif 258 259" flag an octal number with wrong digits 260syn match cOctalError display contained "0\o * [ 89 ] \d * " 261syn case match 262 263if exists ( "c_comment_strings" ) 264" A comment can contain cString, cCharacter and cNumber. 265" But a "*/" inside a cString in a cComment DOES end the comment! So we 266" need to use a special type of cString: cCommentString, which also ends on 267" "*/", and sees a "*" at the start of the line as comment again. 268" Unfortunately this doesn't very well work for // type of comments :-( 269syn match cCommentSkip contained "^\s * \*\%($\|\s\+\) " 270syn region cCommentString contained start = +L\=\\\@<!" +skip = +\\\\\|\\" +end = +" +end = +\*/ +me= s-1contains = cSpecial , cCommentSkip 271syn region cComment2String contained start = +L\=\\\@<!" +skip = +\\\\\|\\" +end = +" +end = "$ "contains = cSpecial 272syn region cCommentL start = "// "skip = "\\$ "end = "$ "keepend contains = @cCommentGroup , cComment2String , cCharacter , cNumbersCom , cSpaceError , cWrongComTail , @Spell 273if exists ( "c_no_comment_fold" ) 274" Use "extend" here to have preprocessor lines not terminate halfway a 275" comment. 276syn region cComment matchgroup = cCommentStart start = "/\* "end = "\*/ "contains = @cCommentGroup , cCommentStartError , cCommentString , cCharacter , cNumbersCom , cSpaceError , @Spell extend 277else 278syn region cComment matchgroup = cCommentStart start = "/\* "end = "\*/ "contains = @cCommentGroup , cCommentStartError , cCommentString , cCharacter , cNumbersCom , cSpaceError , @Spell fold extend 279endif 280else 281syn region cCommentL start = "// "skip = "\\$ "end = "$ "keepend contains = @cCommentGroup , cSpaceError , @Spell 282if exists ( "c_no_comment_fold" ) 283syn region cComment matchgroup = cCommentStart start = "/\* "end = "\*/ "contains = @cCommentGroup , cCommentStartError , cSpaceError , @Spell extend 284else 285syn region cComment matchgroup = cCommentStart start = "/\* "end = "\*/ "contains = @cCommentGroup , cCommentStartError , cSpaceError , @Spell fold extend 286endif 287endif 288" keep a // comment separately, it terminates a preproc. conditional 289syn match cCommentError display "\*/ " 290syn match cCommentStartError display "/\* "me= e-1contained 291syn match cWrongComTail display "\*/ " 292 293syn keyword cOperator sizeof 294if exists ( "c_gnu" ) 295syn keyword cType __label__ __complex__ 296syn keyword cStatement __asm__ 297syn keyword cOperator __alignof__ 298syn keyword cOperator typeof __typeof__ 299syn keyword cOperator __real__ __imag__ 300syn keyword cStorageClass __attribute__ __extension__ 301syn keyword cTypeQualifier __const__ __restrict__ __volatile__ 302syn keyword cFunctionSpec inline __inline __inline__ __noreturn__ 303endif 304syn keyword cType int long short char void 305syn keyword cType signed unsigned float double 306if ! exists ( "c_no_ansi" ) || exists ( "c_ansi_typedefs" ) 307syn keyword cType size_t ssize_t off_t wchar_t ptrdiff_t sig_atomic_t fpos_t 308syn keyword cType clock_t time_t va_list jmp_buf FILE DIR div_t ldiv_t 309syn keyword cType mbstate_t wctrans_t wint_t wctype_t 310endif 311if ! exists ( "c_no_c99" ) " ISO C99 312syn keyword cType _Bool bool _Complex complex _Imaginary imaginary 313syn keyword cType int8_t int16_t int32_t int64_t 314syn keyword cType uint8_t uint16_t uint32_t uint64_t 315if ! exists ( "c_no_bsd" ) 316" These are BSD specific. 317syn keyword cType u_int8_t u_int16_t u_int32_t u_int64_t 318endif 319syn keyword cType int_least8_t int_least16_t int_least32_t int_least64_t 320syn keyword cType uint_least8_t uint_least16_t uint_least32_t uint_least64_t 321syn keyword cType int_fast8_t int_fast16_t int_fast32_t int_fast64_t 322syn keyword cType uint_fast8_t uint_fast16_t uint_fast32_t uint_fast64_t 323syn keyword cType intptr_t uintptr_t 324syn keyword cType intmax_t uintmax_t 325endif 326if ! exists ( "c_no_c23" ) && ! s: in_cpp_family 327syn keyword cOperator typeof typeof_unqual 328syn keyword cType _BitInt _Decimal32 _Decimal64 _Decimal128 329endif 330if ( s: ft ==# "c" && ! exists ( "c_no_c23" )) || ( s: in_cpp_family && ! exists ( "cpp_no_cpp11" )) 331syn keyword cType nullptr_t 332endif 333 334syn keyword cTypedef typedef 335syn keyword cStructure struct union enum 336syn keyword cStorageClass static register auto extern 337syn keyword cTypeQualifier const volatile 338if ! exists ( "c_no_c99" ) && ! s: in_cpp_family 339syn keyword cFunctionSpec inline 340syn keyword cTypeQualifier restrict 341endif 342if ( s: ft ==# "c" && ! exists ( "c_no_c23" )) || ( s: in_cpp_family && ! exists ( "cpp_no_cpp11" )) 343syn keyword cStorageClass constexpr 344endif 345if ! exists ( "c_no_c11" ) 346syn keyword cStorageClass _Alignas alignas 347syn keyword cOperator _Alignof alignof 348syn keyword cTypeQualifier _Atomic 349syn keyword cOperator _Generic 350syn keyword cFunctionSpec _Noreturn 351if ! s: in_cpp_family 352syn keyword cStandardAttribute noreturn 353endif 354syn keyword cOperator _Static_assert static_assert 355syn keyword cStorageClass _Thread_local thread_local 356syn keyword cType char16_t char32_t 357syn keyword cType max_align_t 358" C11 atomics (take down the shield wall!) 359syn keyword cType atomic_bool atomic_char atomic_schar atomic_uchar 360syn keyword Ctype atomic_short atomic_ushort atomic_int atomic_uint 361syn keyword cType atomic_long atomic_ulong atomic_llong atomic_ullong 362syn keyword cType atomic_char16_t atomic_char32_t atomic_wchar_t 363syn keyword cType atomic_int_least8_t atomic_uint_least8_t 364syn keyword cType atomic_int_least16_t atomic_uint_least16_t 365syn keyword cType atomic_int_least32_t atomic_uint_least32_t 366syn keyword cType atomic_int_least64_t atomic_uint_least64_t 367syn keyword cType atomic_int_fast8_t atomic_uint_fast8_t 368syn keyword cType atomic_int_fast16_t atomic_uint_fast16_t 369syn keyword cType atomic_int_fast32_t atomic_uint_fast32_t 370syn keyword cType atomic_int_fast64_t atomic_uint_fast64_t 371syn keyword cType atomic_intptr_t atomic_uintptr_t 372syn keyword cType atomic_size_t atomic_ptrdiff_t 373syn keyword cType atomic_intmax_t atomic_uintmax_t 374endif 375 376if ! exists ( "c_no_c23" ) && ! s: in_cpp_family 377syn keyword cStandardAttribute deprecated fallthrough maybe_unused nodiscard 378syn keyword cStandardAttribute unsequenced reproducible 379endif 380 381if ( s: ft ==# "c" && ! exists ( "c_no_c23" )) || ( s: in_cpp_family && ! exists ( "cpp_no_cpp20" )) 382syn keyword cType char8_t 383endif 384 385if ! exists ( "c_no_ansi" ) || exists ( "c_ansi_constants" ) || exists ( "c_gnu" ) 386if exists ( "c_gnu" ) 387syn keyword cConstant __GNUC__ __FUNCTION__ __PRETTY_FUNCTION__ __func__ 388endif 389" TODO: __STDC_HOSTED__ is C99 and C++11 390syn keyword cConstant __LINE__ __FILE__ __DATE__ __TIME__ __STDC__ __STDC_VERSION__ __STDC_HOSTED__ 391syn keyword cConstant CHAR_BIT MB_LEN_MAX MB_CUR_MAX 392syn keyword cConstant UCHAR_MAX UINT_MAX ULONG_MAX USHRT_MAX 393syn keyword cConstant CHAR_MIN INT_MIN LONG_MIN SHRT_MIN 394syn keyword cConstant CHAR_MAX INT_MAX LONG_MAX SHRT_MAX 395syn keyword cConstant SCHAR_MIN SINT_MIN SLONG_MIN SSHRT_MIN 396syn keyword cConstant SCHAR_MAX SINT_MAX SLONG_MAX SSHRT_MAX 397if ! exists ( "c_no_c99" ) 398syn keyword cConstant __STDC_ISO_10646__ __STDC_IEC_559_COMPLEX__ 399syn keyword cConstant __STDC_MB_MIGHT_NEQ_WC__ 400syn keyword cConstant __func__ __VA_ARGS__ 401syn keyword cConstant LLONG_MIN LLONG_MAX ULLONG_MAX 402syn keyword cConstant INT8_MIN INT16_MIN INT32_MIN INT64_MIN 403syn keyword cConstant INT8_MAX INT16_MAX INT32_MAX INT64_MAX 404syn keyword cConstant UINT8_MAX UINT16_MAX UINT32_MAX UINT64_MAX 405syn keyword cConstant INT_LEAST8_MIN INT_LEAST16_MIN INT_LEAST32_MIN INT_LEAST64_MIN 406syn keyword cConstant INT_LEAST8_MAX INT_LEAST16_MAX INT_LEAST32_MAX INT_LEAST64_MAX 407syn keyword cConstant UINT_LEAST8_MAX UINT_LEAST16_MAX UINT_LEAST32_MAX UINT_LEAST64_MAX 408syn keyword cConstant INT_FAST8_MIN INT_FAST16_MIN INT_FAST32_MIN INT_FAST64_MIN 409syn keyword cConstant INT_FAST8_MAX INT_FAST16_MAX INT_FAST32_MAX INT_FAST64_MAX 410syn keyword cConstant UINT_FAST8_MAX UINT_FAST16_MAX UINT_FAST32_MAX UINT_FAST64_MAX 411syn keyword cConstant INTPTR_MIN INTPTR_MAX UINTPTR_MAX 412syn keyword cConstant INTMAX_MIN INTMAX_MAX UINTMAX_MAX 413syn keyword cConstant PTRDIFF_MIN PTRDIFF_MAX SIG_ATOMIC_MIN SIG_ATOMIC_MAX 414syn keyword cConstant SIZE_MAX WCHAR_MIN WCHAR_MAX WINT_MIN WINT_MAX 415endif 416if ! exists ( "c_no_c11" ) 417syn keyword cConstant __STDC_UTF_16__ __STDC_UTF_32__ __STDC_ANALYZABLE__ 418syn keyword cConstant __STDC_LIB_EXT1__ __STDC_NO_ATOMICS__ 419syn keyword cConstant __STDC_NO_COMPLEX__ __STDC_NO_THREADS__ 420syn keyword cConstant __STDC_NO_VLA__ 421endif 422if ! exists ( "c_no_c23" ) 423syn keyword cConstant __STDC_UTF_16__ __STDC_UTF_32__ 424syn keyword cConstant __STDC_EMBED_NOT_FOUND__ __STDC_EMBED_FOUND__ 425syn keyword cConstant __STDC_EMBED_EMPTY__ __STDC_IEC_60559_BFP__ 426syn keyword cConstant __STDC_IEC_60559_DFP__ __STDC_IEC_60559_COMPLEX__ 427syn keyword cConstant __STDC_IEC_60559_TYPES__ 428syn keyword cConstant BITINT_MAXWIDTH 429endif 430if ( s: ft ==# "c" && ! exists ( "c_no_c23" )) || ( s: in_cpp_family && ! exists ( "cpp_no_cpp20" )) 431syn keyword cConstant __VA_OPT__ 432endif 433if ( s: ft ==# "c" && ! exists ( "c_no_c23" )) || ( s: in_cpp_family && ! exists ( "cpp_no_cpp11" )) 434syn keyword cConstant nullptr 435endif 436syn keyword cConstant FLT_RADIX FLT_ROUNDS FLT_DIG FLT_MANT_DIG FLT_EPSILON DBL_DIG DBL_MANT_DIG DBL_EPSILON 437syn keyword cConstant LDBL_DIG LDBL_MANT_DIG LDBL_EPSILON FLT_MIN FLT_MAX FLT_MIN_EXP FLT_MAX_EXP FLT_MIN_10_EXP FLT_MAX_10_EXP 438syn keyword cConstant DBL_MIN DBL_MAX DBL_MIN_EXP DBL_MAX_EXP DBL_MIN_10_EXP DBL_MAX_10_EXP LDBL_MIN LDBL_MAX LDBL_MIN_EXP LDBL_MAX_EXP 439syn keyword cConstant LDBL_MIN_10_EXP LDBL_MAX_10_EXP HUGE_VAL CLOCKS_PER_SEC NULL LC_ALL LC_COLLATE LC_CTYPE LC_MONETARY 440syn keyword cConstant LC_NUMERIC LC_TIME SIG_DFL SIG_ERR SIG_IGN SIGABRT SIGFPE SIGILL SIGHUP SIGINT SIGSEGV SIGTERM 441" Add POSIX signals as well... 442syn keyword cConstant SIGABRT SIGALRM SIGCHLD SIGCONT SIGFPE SIGHUP SIGILL SIGINT SIGKILL SIGPIPE SIGQUIT SIGSEGV 443syn keyword cConstant SIGSTOP SIGTERM SIGTRAP SIGTSTP SIGTTIN SIGTTOU SIGUSR1 SIGUSR2 444syn keyword cConstant _IOFBF _IOLBF _IONBF BUFSIZ EOF WEOF FOPEN_MAX FILENAME_MAX L_tmpnam 445syn keyword cConstant SEEK_CUR SEEK_END SEEK_SET TMP_MAX EXIT_FAILURE EXIT_SUCCESS RAND_MAX 446syn keyword cConstant stdin stdout stderr 447" POSIX 2001, in unistd.h 448syn keyword cConstant STDIN_FILENO STDOUT_FILENO STDERR_FILENO 449" used in assert.h 450syn keyword cConstant NDEBUG 451" POSIX 2001 452syn keyword cConstant SIGBUS SIGPOLL SIGPROF SIGSYS SIGURG SIGVTALRM SIGXCPU SIGXFSZ 453" POSIX Issue 8 (post 2017) 454syn keyword cConstant SIGWINCH 455" non-POSIX signals 456syn keyword cConstant SIGINFO SIGIO 457" Add POSIX errors as well. List comes from: 458" http://pubs.opengroup.org/onlinepubs/9699919799/basedefs/errno.h.html 459syn keyword cConstant E2BIG EACCES EADDRINUSE EADDRNOTAVAIL EAFNOSUPPORT EAGAIN EALREADY EBADF 460syn keyword cConstant EBADMSG EBUSY ECANCELED ECHILD ECONNABORTED ECONNREFUSED ECONNRESET EDEADLK 461syn keyword cConstant EDESTADDRREQ EDOM EDQUOT EEXIST EFAULT EFBIG EHOSTUNREACH EIDRM EILSEQ 462syn keyword cConstant EINPROGRESS EINTR EINVAL EIO EISCONN EISDIR ELOOP EMFILE EMLINK EMSGSIZE 463syn keyword cConstant EMULTIHOP ENAMETOOLONG ENETDOWN ENETRESET ENETUNREACH ENFILE ENOBUFS ENODATA 464syn keyword cConstant ENODEV ENOENT ENOEXEC ENOLCK ENOLINK ENOMEM ENOMSG ENOPROTOOPT ENOSPC ENOSR 465syn keyword cConstant ENOSTR ENOSYS ENOTBLK ENOTCONN ENOTDIR ENOTEMPTY ENOTRECOVERABLE ENOTSOCK ENOTSUP 466syn keyword cConstant ENOTTY ENXIO EOPNOTSUPP EOVERFLOW EOWNERDEAD EPERM EPIPE EPROTO 467syn keyword cConstant EPROTONOSUPPORT EPROTOTYPE ERANGE EROFS ESPIPE ESRCH ESTALE ETIME ETIMEDOUT 468syn keyword cConstant ETXTBSY EWOULDBLOCK EXDEV 469" math.h 470syn keyword cConstant M_E M_LOG2E M_LOG10E M_LN2 M_LN10 M_PI M_PI_2 M_PI_4 471syn keyword cConstant M_1_PI M_2_PI M_2_SQRTPI M_SQRT2 M_SQRT1_2 472endif 473if ! exists ( "c_no_c99" ) " ISO C99 474syn keyword cConstant true false 475syn keyword cConstant INFINITY NAN 476" math.h 477syn keyword cConstant HUGE_VAL HUGE_VALF HUGE_VALL 478syn keyword cConstant FP_FAST_FMAF FP_FAST_FMA FP_FAST_FMAL 479syn keyword cConstant FP_ILOGB0 FP_ILOGBNAN 480syn keyword cConstant math_errhandling MATH_ERRNO MATH_ERREXCEPT 481syn keyword cConstant FP_NORMAL FP_SUBNORMAL FP_ZERO FP_INFINITE FP_NAN 482endif 483 484" Accept %: for # (C99) 485syn cluster cPreProcGroup contains = cPreCondit , cIncluded , cInclude , cDefine , cErrInParen , cErrInBracket , cUserLabel , cSpecial , cOctalZero , cCppOutWrapper , cCppInWrapper , @cCppOutInGroup , cFormat , cNumber , cFloat , cOctal , cOctalError , cNumbersCom , cString , cCommentSkip , cCommentString , cComment2String , @cCommentGroup , cCommentStartError , cParen , cBracket , cMulti , cBadBlock 486if ! exists ( "c_no_c23" ) 487syn region cPreCondit start = "^\s * \zs\%(%:\|#\)\s * \%(el\)\=\%(if\|ifdef\|ifndef\)\> "skip = "\\$ "end = "$ "keepend contains = cComment , cCommentL , cCppString , cCharacter , cCppParen , cParenError , cNumbers , cCommentError , cSpaceError 488else 489syn region cPreCondit start = "^\s * \zs\%(%:\|#\)\s * \%(if\|ifdef\|ifndef\|elif\)\> "skip = "\\$ "end = "$ "keepend contains = cComment , cCommentL , cCppString , cCharacter , cCppParen , cParenError , cNumbers , cCommentError , cSpaceError 490endif 491syn match cPreConditMatch display "^\s * \zs\%(%:\|#\)\s * \%(else\|endif\)\> " 492if ! exists ( "c_no_if0" ) 493syn cluster cCppOutInGroup contains = cCppInIf , cCppInElse , cCppInElse2 , cCppOutIf , cCppOutIf2 , cCppOutElse , cCppInSkip , cCppOutSkip 494syn region cCppOutWrapper start = "^\s * \zs\%(%:\|#\)\s * if\s\+0\+\s * \%($\|//\|/\*\|&\) "end = ".\@=\|$ "contains = cCppOutIf , cCppOutElse , @NoSpell fold 495syn region cCppOutIf contained start = "0\+ "matchgroup = cCppOutWrapper end = "^\s * \%(%:\|#\)\s * endif\> "contains = cCppOutIf2 , cCppOutElse 496if ! exists ( "c_no_if0_fold" ) 497if ! exists ( "c_no_c23" ) 498syn region cCppOutIf2 contained matchgroup = cCppOutWrapper start = "0\+ "end = "^\s * \%(%:\|#\)\s * \%(else\>\|el\%(if\|ifdef\|ifndef\)\s\+\%(0\+\s * \%($\|//\|/\*\|&\)\)\@!\|endif\>\) "me= s-1contains = cSpaceError , cCppOutSkip , @Spell fold 499else 500syn region cCppOutIf2 contained matchgroup = cCppOutWrapper start = "0\+ "end = "^\s * \%(%:\|#\)\s * \%(else\>\|elif\s\+\%(0\+\s * \%($\|//\|/\*\|&\)\)\@!\|endif\>\) "me= s-1contains = cSpaceError , cCppOutSkip , @Spell fold 501endif 502else 503if ! exists ( "c_no_c23" ) 504syn region cCppOutIf2 contained matchgroup = cCppOutWrapper start = "0\+ "end = "^\s * \%(%:\|#\)\s * \%(else\>\|el\%(if\|ifdef\|ifndef\)\s\+\%(0\+\s * \%($\|//\|/\*\|&\)\)\@!\|endif\>\) "me= s-1contains = cSpaceError , cCppOutSkip , @Spell 505else 506syn region cCppOutIf2 contained matchgroup = cCppOutWrapper start = "0\+ "end = "^\s * \%(%:\|#\)\s * \%(else\>\|elif\s\+\%(0\+\s * \%($\|//\|/\*\|&\)\)\@!\|endif\>\) "me= s-1contains = cSpaceError , cCppOutSkip , @Spell 507endif 508endif 509if ! exists ( "c_no_c23" ) 510syn region cCppOutElse contained matchgroup = cCppOutWrapper start = "^\s * \%(%:\|#\)\s * \%(else\|el\%(if\|ifdef\|ifndef\)\) "end = "^\s * \%(%:\|#\)\s * endif\> "me= s-1contains = TOP , cPreCondit 511else 512syn region cCppOutElse contained matchgroup = cCppOutWrapper start = "^\s * \%(%:\|#\)\s * \%(else\|elif\) "end = "^\s * \%(%:\|#\)\s * endif\> "me= s-1contains = TOP , cPreCondit 513endif 514syn region cCppInWrapper start = "^\s * \zs\%(%:\|#\)\s * if\s\+0 * [ 1-9 ] \d * \s * \%($\|//\|/\*\||\) "end = ".\@=\|$ "contains = cCppInIf , cCppInElse fold 515syn region cCppInIf contained matchgroup = cCppInWrapper start = "\d\+ "end = "^\s * \%(%:\|#\)\s * endif\> "contains = TOP , cPreCondit 516if ! exists ( "c_no_if0_fold" ) 517if ! exists ( "c_no_c23" ) 518syn region cCppInElse contained start = "^\s * \%(%:\|#\)\s * \%(else\>\|el\%(if\|ifdef\|ifndef\)\s\+\%(0 * [ 1-9 ] \d * \s * \%($\|//\|/\*\||\)\)\@!\) "end = ".\@=\|$ "containedin = cCppInIf contains = cCppInElse2 fold 519else 520syn region cCppInElse contained start = "^\s * \%(%:\|#\)\s * \%(else\>\|elif\s\+\%(0 * [ 1-9 ] \d * \s * \%($\|//\|/\*\||\)\)\@!\) "end = ".\@=\|$ "containedin = cCppInIf contains = cCppInElse2 fold 521endif 522else 523if ! exists ( "c_no_c23" ) 524syn region cCppInElse contained start = "^\s * \%(%:\|#\)\s * \%(else\>\|el\%(if\|ifdef\|ifndef\)\s\+\%(0 * [ 1-9 ] \d * \s * \%($\|//\|/\*\||\)\)\@!\) "end = ".\@=\|$ "containedin = cCppInIf contains = cCppInElse2 525else 526syn region cCppInElse contained start = "^\s * \%(%:\|#\)\s * \%(else\>\|elif\s\+\%(0 * [ 1-9 ] \d * \s * \%($\|//\|/\*\||\)\)\@!\) "end = ".\@=\|$ "containedin = cCppInIf contains = cCppInElse2 527endif 528endif 529if ! exists ( "c_no_c23" ) 530syn region cCppInElse2 contained matchgroup = cCppInWrapper start = "^\s * \%(%:\|#\)\s * \%(else\|el\%(if\|ifdef\|ifndef\)\)\%( [ ^/ ] \|/ [ ^/* ] \) * "end = "^\s * \%(%:\|#\)\s * endif\> "me= s-1contains = cSpaceError , cCppOutSkip , @Spell 531else 532syn region cCppInElse2 contained matchgroup = cCppInWrapper start = "^\s * \%(%:\|#\)\s * \%(else\|elif\)\%( [ ^/ ] \|/ [ ^/* ] \) * "end = "^\s * \%(%:\|#\)\s * endif\> "me= s-1contains = cSpaceError , cCppOutSkip , @Spell 533endif 534syn region cCppOutSkip contained start = "^\s * \%(%:\|#\)\s * \%(if\>\|ifdef\>\|ifndef\>\) "skip = "\\$ "end = "^\s * \%(%:\|#\)\s * endif\> "contains = cSpaceError , cCppOutSkip 535syn region cCppInSkip contained matchgroup = cCppInWrapper start = "^\s * \%(%:\|#\)\s * \%(if\s\+\%(\d\+\s * \%($\|//\|/\*\||\|&\)\)\@!\|ifdef\>\|ifndef\>\) "skip = "\\$ "end = "^\s * \%(%:\|#\)\s * endif\> "containedin = cCppOutElse , cCppInIf , cCppInSkip contains = TOP , cPreProc 536endif 537syn region cIncluded display contained start = +" +skip = +\\\\\|\\" +end = +" + 538syn match cIncluded display contained "< [ ^> ] * > " 539syn match cInclude display "^\s * \zs\%(%:\|#\)\s * include\>\s * [ "< ] "contains = cIncluded 540if ! exists ( "c_no_c23" ) && ! s: in_cpp_family 541syn region cInclude start = "^\s * \zs\%(%:\|#\)\s * embed\> "skip = "\\$ "end = "$ "keepend contains = cEmbed , cComment , cCommentL , cCppString , cCharacter , cCppParen , cParenError , cNumbers , cCommentError , cSpaceError 542syn match cEmbed contained "\%(%:\|#\)\s * embed\> "nextgroup = cIncluded skipwhite transparent 543syn cluster cPreProcGroup add = cEmbed 544endif 545"syn match cLineSkip "\\$" 546syn region cDefine start = "^\s * \zs\%(%:\|#\)\s * \%(define\|undef\)\> "skip = "\\$ "end = "$ "keepend contains = ALLBUT , @cPreProcGroup , @Spell 547syn region cPreProc start = "^\s * \zs\%(%:\|#\)\s * \%(pragma\>\|line\>\|warning\>\|warn\>\|error\>\) "skip = "\\$ "end = "$ "keepend contains = ALLBUT , @cPreProcGroup , @Spell 548 549" Optional embedded Autodoc parsing 550if exists ( "c_autodoc" ) 551syn match cAutodocReal display contained "\%(//\| [ / \t\v ] \*\|^\*\)\@2<=!. * "contains = @cAutodoc containedin = cComment , cCommentL 552syn cluster cCommentGroup add = cAutodocReal 553syn cluster cPreProcGroup add = cAutodocReal 554endif 555 556" be able to fold #pragma regions 557syn region cPragma start = "^\s * #pragma\s\+region\> "end = "^\s * #pragma\s\+endregion\> "transparent keepend extend fold 558 559" Highlight User Labels 560syn cluster cMultiGroup contains = cIncluded , cSpecial , cCommentSkip , cCommentString , cComment2String , @cCommentGroup , cCommentStartError , cUserCont , cUserLabel , cBitField , cOctalZero , cCppOutWrapper , cCppInWrapper , @cCppOutInGroup , cFormat , cNumber , cFloat , cOctal , cOctalError , cNumbersCom , cCppParen , cCppBracket , cCppString 561if s: ft ==# 'c' || exists ( "cpp_no_cpp11" ) 562syn region cMulti transparent start = '? 'skip = ':: 'end = ': 'contains = ALLBUT , @cMultiGroup , @Spell , @cStringGroup 563endif 564" Avoid matching foo::bar() in C++ by requiring that the next char is not ':' 565syn cluster cLabelGroup contains = cUserLabel 566syn match cUserCont display "^\s * \zs\I\i * \s * :$ "contains = @cLabelGroup 567syn match cUserCont display ";\s * \zs\I\i * \s * :$ "contains = @cLabelGroup 568if s: in_cpp_family 569syn match cUserCont display "^\s * \zs\%(class\|struct\|enum\)\@!\I\i * \s * : [ ^: ] "me= e-1contains = @cLabelGroup 570syn match cUserCont display ";\s * \zs\%(class\|struct\|enum\)\@!\I\i * \s * : [ ^: ] "me= e-1contains = @cLabelGroup 571else 572syn match cUserCont display "^\s * \zs\I\i * \s * : [ ^: ] "me= e-1contains = @cLabelGroup 573syn match cUserCont display ";\s * \zs\I\i * \s * : [ ^: ] "me= e-1contains = @cLabelGroup 574endif 575 576syn match cUserLabel display "\I\i * "contained 577 578" Avoid recognizing most bitfields as labels 579syn match cBitField display "^\s * \zs\I\i * \s * :\s * [ 1-9 ] "me= e-1contains = cType 580syn match cBitField display ";\s * \zs\I\i * \s * :\s * [ 1-9 ] "me= e-1contains = cType 581 582if exists ( "c_functions" ) 583syn match cFunction "\<\h\w * \ze\_s * ( " 584endif 585 586if exists ( "c_function_pointers" ) 587syn match cFunctionPointer "\%((\s * \*\s * \)\@<=\h\w * \ze\s * )\_s * (. * ) " 588endif 589 590if exists ( "c_minlines" ) 591let b: c_minlines = c_minlines 592else 593if ! exists ( "c_no_if0" ) 594let b: c_minlines = 50 " #if 0 constructs can be long 595else 596let b: c_minlines = 15 " mostly for () constructs 597endif 598endif 599if exists ( "c_curly_error" ) 600syn sync fromstart 601else 602exec "syn sync ccomment cComment minlines=" . b: c_minlines 603endif 604 605" Define the default highlighting. 606" Only used when an item doesn't have highlighting yet 607hi def link cFormat cSpecial 608hi def link cCppString cString 609hi def link cCommentL cComment 610hi def link cCommentStart cComment 611hi def link cLabel Label 612hi def link cUserLabel Label 613hi def link cConditional Conditional 614hi def link cRepeat Repeat 615hi def link cCharacter Character 616hi def link cSpecialCharacter cSpecial 617hi def link cNumber Number 618hi def link cOctal Number 619hi def link cOctalZero PreProc " link this to Error if you want 620hi def link cFloat Float 621hi def link cOctalError cError 622hi def link cParenError cError 623hi def link cErrInParen cError 624hi def link cErrInBracket cError 625hi def link cCommentError cError 626hi def link cCommentStartError cError 627hi def link cSpaceError cError 628hi def link cWrongComTail cError 629hi def link cSpecialError cError 630hi def link cCurlyError cError 631hi def link cOperator Operator 632hi def link cStructure Structure 633hi def link cTypedef Structure 634hi def link cStorageClass StorageClass 635hi def link cTypeQualifier cStorageClass 636hi def link cFunctionSpec cStorageClass 637hi def link cStandardAttribute cStorageClass 638hi def link cInclude Include 639hi def link cPreProc PreProc 640hi def link cDefine Macro 641hi def link cIncluded cString 642hi def link cError Error 643hi def link cStatement Statement 644hi def link cCppInWrapper cCppOutWrapper 645hi def link cCppOutWrapper cPreCondit 646hi def link cPreConditMatch cPreCondit 647hi def link cPreCondit PreCondit 648hi def link cType Type 649hi def link cConstant Constant 650hi def link cCommentString cString 651hi def link cComment2String cString 652hi def link cCommentSkip cComment 653hi def link cString String 654hi def link cComment Comment 655hi def link cSpecial SpecialChar 656hi def link cTodo Todo 657hi def link cBadContinuation Error 658hi def link cCppOutSkip cCppOutIf2 659hi def link cCppInElse2 cCppOutIf2 660hi def link cCppOutIf2 cCppOut 661hi def link cCppOut Comment 662hi def link cFunction Function 663hi def link cFunctionPointer Function 664 665let b: current_syntax = "c" 666 667unlet s: ft 668 669let & cpo = s: cpo_save 670unlet s: cpo_save 671" vim: ts=8