From 3c4c8af4b40234cc835d0271bf49e7718d21c2f8 Mon Sep 17 00:00:00 2001 From: Caleb Maclennan Date: Thu, 2 Jan 2020 08:01:13 +0300 Subject: [PATCH] Test whether &termencoding even exists before use Fixes #574 See also: * https://github.com/neovim/neovim/pull/2631 * https://github.com/neovim/neovim/issues/7445 * https://github.com/vim/vim/commit/ac360bf2ca293735fc7c6654dc2b3066f4c62488 --- plugin/tagbar.vim | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/plugin/tagbar.vim b/plugin/tagbar.vim index 4198a19..5900f1f 100644 --- a/plugin/tagbar.vim +++ b/plugin/tagbar.vim @@ -86,7 +86,7 @@ call s:setup_options() if !exists('g:tagbar_iconchars') if has('multi_byte') && has('unix') && &encoding ==# 'utf-8' && - \ (empty(&termencoding) || &termencoding ==# 'utf-8') + \ (!exists('+termencoding') || empty(&termencoding) || &termencoding ==# 'utf-8') let g:tagbar_iconchars = ['▶', '▼'] else let g:tagbar_iconchars = ['+', '-']