From 7cf83a433098c0a107998d3a84518282f27098d1 Mon Sep 17 00:00:00 2001 From: raven42 Date: Wed, 6 Jan 2021 06:24:14 -0600 Subject: [PATCH] Check for tilde in cpp destructor (#732) --- autoload/tagbar/prototypes/normaltag.vim | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/autoload/tagbar/prototypes/normaltag.vim b/autoload/tagbar/prototypes/normaltag.vim index df21692..a192f97 100644 --- a/autoload/tagbar/prototypes/normaltag.vim +++ b/autoload/tagbar/prototypes/normaltag.vim @@ -152,7 +152,8 @@ function! s:getDataType() abort dict endif let line = getbufline(bufnr, self.fields.line)[0] - let data_type = substitute(line, '\s*' . self.name . '.*', '', '') + let tmp_name = substitute(self.name, "\\~", '', 'g') + let data_type = substitute(line, '\s*' . tmp_name . '.*', '', '') " Strip off the path if we have one along with any spaces prior to the " path