Permalink
Browse files

Escape comment char, before trying to conceal it

need to escape the comment char, else syntax highlight might throw an
ugly error (fixes #25)
  • Loading branch information...
1 parent df57925 commit b1fd550d14bdbec4b0ce13d9d5fac547c97a72c5 @chrisbra committed Feb 19, 2014
Showing with 1 addition and 0 deletions.
  1. +1 −0 autoload/nrrwrgn.vim
View
@@ -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\+$"'

0 comments on commit b1fd550

Please sign in to comment.