Make the circumflex and the dollar sign optional...

...when parsing the pattern part of the ctags output

http://pubs.opengroup.org/onlinepubs/009695399/utilities/ctags.html#tag_04_30_12

Closes #257
This commit is contained in:
Christopher 2012-08-17 22:35:23 +02:00 committed by Kien N
parent c2a962786a
commit 2bac5d9cca

View File

@ -183,7 +183,7 @@ fu! s:process(fname, ftype)
endf
fu! s:parseline(line)
let eval = '\v^([^\t]+)\t(.+)\t\/\^(.+)\$\/\;\"\t(.+)\tline(no)?\:(\d+)'
let eval = '\v^([^\t]+)\t(.+)\t\/\^?(.+)\$?\/\;\"\t(.+)\tline(no)?\:(\d+)'
let vals = matchlist(a:line, eval)
if vals == [] | retu '' | en
let [bufnr, bufname] = [bufnr('^'.vals[2].'$'), fnamemodify(vals[2], ':p:t')]