Skip to content
Browse files

Work around a statusline bug in Vim < 7.1.097

  • Loading branch information...
1 parent 4bc7555 commit 5c50b77a5a987a0931fa524ced6a5ab7e4dfbedf @majutsushi committed Nov 25, 2011
Showing with 6 additions and 1 deletion.
  1. +6 −1 autoload/tagbar.vim
View
7 autoload/tagbar.vim
@@ -1461,7 +1461,12 @@ function! s:InitWindow(autoclose)
setlocal foldmethod&
setlocal foldexpr&
- setlocal statusline=%!TagbarGenerateStatusline()
+ " Earlier versions have a bug in local, evaluated statuslines
+ if v:version > 701 || (v:version == 701 && has('patch097'))
+ setlocal statusline=%!TagbarGenerateStatusline()
+ else
+ setlocal statusline=Tagbar
+ endif
" Script-local variable needed since compare functions can't
" take extra arguments

0 comments on commit 5c50b77

Please sign in to comment.
Something went wrong with that request. Please try again.