mirror of
https://github.com/vim/vim.git
synced 2025-10-14 07:04:10 -04:00
patch 8.2.4553: linear tag search is a bit slow
Problem: Linear tag search is a bit slow. Solution: Remove a vim_ftell() call. (Yegappan Lakshmanan, closes #9937)
This commit is contained in:
committed by
Bram Moolenaar
parent
d0b7bfa957
commit
8b530b3158
@@ -2092,10 +2092,7 @@ findtags_get_next_line(findtags_state_T *st, tagsearch_info_T *sinfo_p)
|
||||
eof = cs_fgets(st->lbuf, st->lbuf_size);
|
||||
else
|
||||
#endif
|
||||
{
|
||||
sinfo_p->curr_offset = vim_ftell(st->fp);
|
||||
eof = vim_fgets(st->lbuf, st->lbuf_size, st->fp);
|
||||
}
|
||||
} while (!eof && vim_isblankline(st->lbuf));
|
||||
|
||||
if (eof)
|
||||
@@ -2850,7 +2847,7 @@ line_read_in:
|
||||
return;
|
||||
}
|
||||
|
||||
if (st->state == TS_STEP_FORWARD)
|
||||
if (st->state == TS_STEP_FORWARD || st->state == TS_LINEAR)
|
||||
// Seek to the same position to read the same line again
|
||||
vim_ignored = vim_fseek(st->fp, search_info.curr_offset,
|
||||
SEEK_SET);
|
||||
|
Reference in New Issue
Block a user