" Language: C
" Last Change: 2008 Mar 05
$ cat test.c
#define TEST 4 /* hello
comment */
--
Dasn
Works fine for me. Try using ftp://ftp.vim.org/pub/vim/runtime/syntax/c.vim
Why is it that so many people don't sign messages with their real name?
It's like talking to people in a completely dark room.
--
hundred-and-one symptoms of being an internet addict:
143. You dream in pallettes of 216 websafe colors.
/// Bram Moolenaar -- Br...@Moolenaar.net -- http://www.Moolenaar.net \\\
/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\
\\\ download, build and distribute -- http://www.A-A-P.org ///
\\\ help me help AIDS victims -- http://ICCF-Holland.org ///
Also broken for me. Using
vim -u /dev/null --noplugin -c "syn on" test.c
:version
VIM - Vi IMproved 7.1 (2007 May 12, compiled Mar 17 2008 15:33:40)
Included patches: 1-283
:!head -4 $VIMRUNTIME/syntax/c.vim
" Vim syntax file
" Language: C
" Maintainer: Bram Moolenaar <Br...@vim.org>
" Last Change: 2008 Mar 05
Solaris, self compiled
--
Vlad
Aha, I didn't see the problem because I have c_comment_strings defined.
Without it I can see the problem. It's easy to fix:
*** c.vim~ Wed Mar 5 12:20:50 2008
--- c.vim Wed Mar 19 21:44:52 2008
***************
*** 149,157 ****
else
syn region cCommentL start="//" skip="\\$" end="$" keepend contains=@cCommentGroup,cSpaceError,@Spell
if exists("c_no_comment_fold")
! syn region cComment matchgroup=cCommentStart start="/\*" end="\*/" contains=@cCommentGroup,cCommentStartError,cSpaceError,@Spell
else
! syn region cComment matchgroup=cCommentStart start="/\*" end="\*/" contains=@cCommentGroup,cCommentStartError,cSpaceError,@Spell fold
endif
endif
" keep a // comment separately, it terminates a preproc. conditional
--- 149,157 ----
else
syn region cCommentL start="//" skip="\\$" end="$" keepend contains=@cCommentGroup,cSpaceError,@Spell
if exists("c_no_comment_fold")
! syn region cComment matchgroup=cCommentStart start="/\*" end="\*/" contains=@cCommentGroup,cCommentStartError,cSpaceError,@Spell extend
else
! syn region cComment matchgroup=cCommentStart start="/\*" end="\*/" contains=@cCommentGroup,cCommentStartError,cSpaceError,@Spell fold extend
endif
endif
" keep a // comment separately, it terminates a preproc. conditional
--
hundred-and-one symptoms of being an internet addict:
155. You forget to eat because you're too busy surfing the net.