Skip to content

Commit 7d9ce35

Browse files
committed
Allow addition of new language types (preservim#789)
1 parent b6669c7 commit 7d9ce35

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

autoload/tagbar.vim

+6
Original file line numberDiff line numberDiff line change
@@ -1397,6 +1397,12 @@ function! s:ExecuteCtagsOnFile(fname, realfname, typeinfo) abort
13971397
let ctags_args += [ '-V' ]
13981398
endif
13991399

1400+
" Define a new language before adding --language-force to the list of
1401+
" arguments
1402+
if has_key(a:typeinfo, 'deflang')
1403+
let ctags_args += ['--langdef=' . expand(a:typeinfo.deflang)]
1404+
endif
1405+
14001406
" Third-party programs may not necessarily make use of this
14011407
if has_key(a:typeinfo, 'ctagstype')
14021408
let ctags_type = a:typeinfo.ctagstype

0 commit comments

Comments
 (0)