Work around archaic encodings

Closes #304.
This commit is contained in:
Tim Pope
2013-02-10 13:01:22 -05:00
parent 1da788a1b0
commit 6462bdb4b9

View File

@@ -683,7 +683,11 @@ endfunction
function! s:stage_info(lnum) abort function! s:stage_info(lnum) abort
let filename = matchstr(getline(a:lnum),'^#\t\zs.\{-\}\ze\%( ([^()[:digit:]]\+)\)\=$') let filename = matchstr(getline(a:lnum),'^#\t\zs.\{-\}\ze\%( ([^()[:digit:]]\+)\)\=$')
let lnum = a:lnum let lnum = a:lnum
if has('multi_byte_encoding')
let colon = '\%(:\|\%uff1a\)' let colon = '\%(:\|\%uff1a\)'
else
let colon = ':'
endif
while lnum && getline(lnum) !~# colon.'$' while lnum && getline(lnum) !~# colon.'$'
let lnum -= 1 let lnum -= 1
endwhile endwhile