mirror of
https://github.com/preservim/tagbar.git
synced 2025-02-15 05:53:00 +08:00
Don't handle sub-kind headers as tags
This commit is contained in:
parent
efca11881d
commit
4eb89e4a53
|
@ -2357,7 +2357,6 @@ function! s:PrintKinds(typeinfo, fileinfo)
|
|||
" Print 'kind' header of following children
|
||||
if !has_key(a:typeinfo.kind2scope, ckind.short)
|
||||
silent put =' [' . ckind.long . ']'
|
||||
let a:fileinfo.tline[line('.')] = tag
|
||||
endif
|
||||
for childtag in childtags
|
||||
call s:PrintTag(childtag, 1,
|
||||
|
@ -2433,11 +2432,12 @@ function! s:PrintTag(tag, depth, fileinfo, typeinfo)
|
|||
let childtags = filter(copy(a:tag.children),
|
||||
\ 'v:val.fields.kind ==# ckind.short')
|
||||
if len(childtags) > 0
|
||||
" Print 'kind' header of following children
|
||||
" Print 'kind' header of following children, but only if they
|
||||
" are not scope-defining tags (since those already have an
|
||||
" identifier)
|
||||
if !has_key(a:typeinfo.kind2scope, ckind.short)
|
||||
silent put =' ' . repeat(' ', a:depth * 2) .
|
||||
\ '[' . ckind.long . ']'
|
||||
let a:fileinfo.tline[line('.')] = a:tag
|
||||
endif
|
||||
for childtag in childtags
|
||||
call s:PrintTag(childtag, a:depth + 1,
|
||||
|
|
Loading…
Reference in New Issue
Block a user