mirror of
https://github.com/gryf/tagbar.git
synced 2025-12-17 11:30:28 +01:00
Correct the name to properly escape out any special chars for the substitution (#740)
This commit is contained in:
@@ -152,11 +152,7 @@ function! s:getDataType() abort dict
|
||||
endif
|
||||
|
||||
let line = getbufline(bufnr, self.fields.line)[0]
|
||||
if (self.name =~# '^\s*\~')
|
||||
let data_type = ''
|
||||
else
|
||||
let data_type = substitute(line, '\s*' . self.name . '.*', '', '')
|
||||
endif
|
||||
let data_type = substitute(line, '\s*' . escape(self.name, '~') . '.*', '', '')
|
||||
|
||||
" Strip off the path if we have one along with any spaces prior to the
|
||||
" path
|
||||
|
||||
Reference in New Issue
Block a user