Skip to content

Commit

Permalink
vim: fix comment highlighting bug
Browse files Browse the repository at this point in the history
Previous commit had a bug that a line which ends with "//" or "/*"
is not correctly highlighted.
  • Loading branch information
klutzy committed Apr 7, 2013
1 parent 7c2a8c4 commit fc26911
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/etc/vim/syntax/rust.vim
Original file line number Diff line number Diff line change
Expand Up @@ -113,8 +113,8 @@ syn match rustCharacter "'\([^'\\]\|\\\(['nrt\\\"]\|x\x\{2}\|u\x\{4}\|U\x\{8
syn region rustCommentDoc start="/\*\*" end="\*/"
syn region rustCommentDoc start="///" skip="\\$" end="$" keepend
syn match rustComment "/\*\*/"
syn region rustComment start="/\*[^\*]" end="\*/" contains=rustTodo
syn region rustComment start="//[^/]" skip="\\$" end="$" contains=rustTodo keepend
syn region rustComment start="/\*\([^\*]\|$\)" end="\*/" contains=rustTodo
syn region rustComment start="//\([^/]\|$\)" skip="\\$" end="$" contains=rustTodo keepend

syn keyword rustTodo contained TODO FIXME XXX NB

Expand Down

0 comments on commit fc26911

Please sign in to comment.