vim-patch:8.2.4538: the find_tags_in_file() function is too long

Problem:    The find_tags_in_file() function is too long.
Solution:   Refactor into smaller functions. (Yegappan Lakshmanan,
            closes vim/vim#9920)

bf40e90dfe

Co-authored-by: Yegappan Lakshmanan <yegappan@yahoo.com>
This commit is contained in:
zeertzjq 2022-11-18 16:20:32 +08:00
parent e41469a5b5
commit 136112a869
2 changed files with 586 additions and 451 deletions

File diff suppressed because it is too large Load Diff

View File

@ -805,11 +805,11 @@ endfunc
" Test for an unsorted tags file
func Test_tag_sort()
call writefile([
let l = [
\ "first\tXfoo\t1",
\ "ten\tXfoo\t3",
\ "six\tXfoo\t2"],
\ 'Xtags')
\ "six\tXfoo\t2"]
call writefile(l, 'Xtags')
set tags=Xtags
let code =<< trim [CODE]
int first() {}
@ -820,7 +820,14 @@ func Test_tag_sort()
call assert_fails('tag first', 'E432:')
" When multiple tag files are not sorted, then message should be displayed
" multiple times
call writefile(l, 'Xtags2')
set tags=Xtags,Xtags2
call assert_fails('tag first', ['E432:', 'E432:'])
call delete('Xtags')
call delete('Xtags2')
call delete('Xfoo')
set tags&
%bwipe