Skip to content

Commit

Permalink
Escape comment char, before trying to conceal it
Browse files Browse the repository at this point in the history
need to escape the comment char, else syntax highlight might throw an
ugly error (fixes #25)
  • Loading branch information
chrisbra committed Feb 19, 2014
1 parent df57925 commit b1fd550
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions autoload/nrrwrgn.vim
Original file line number Diff line number Diff line change
Expand Up @@ -528,6 +528,7 @@ endfun

fun! <sid>HideNrrwRgnLines() "{{{1
let char1 = <sid>ReturnComments()[0]
let char1 = escape(char1, '"\\')
let cmd='syn match NrrwRgnStart "^'.char1.' Start NrrwRgn\d\+$"'
exe cmd
let cmd='syn match NrrwRgnEnd "^'.char1.' End NrrwRgn\d\+$"'
Expand Down

0 comments on commit b1fd550

Please sign in to comment.