On Sat, 10 Dec 2022 10:16:19 +0100
> I mean when i open 'tagbar.vim' in vim, about 4500 lines code.
>
> I feel that the pb comes from the call of executable 'ctags': when you move
> Cursor vertically from top to down, it pass through several functions, and
> tagbar wants to show current function Cursor is in. So it calls many times
> 'ctags executable' and this is causes delay on my win11 Os.
That'll do it. Executing binaries in Windows is costly. I don't know
how tagbar works, but if it depends on the output of a system call
without saving the results for using later, it'll be slow in both
versions of VimScript _and_ Lua. I had to deal with a similar situation
for a simple VimL function that made calls to 'git' three-four times. I
solved it by relying on the fugitive plugin. It saves the pertinent
values in buffer-local variables, so my VimL function didn't need to
call the 'git' binary.
To hammer home my point: if fugitive didn't save the frequently-used git
values, vim users couldn't use fugitive in Windows because of how slow
it would be to execute any fugitive command.
Windows is a pain.
> I am currently trying to port tagbar legacy to vim9script. But if i am
> right, the pb will still be there.
Most probably.
> I have noticed your advise Enan.
> Thank
> Nicolas
The name you assigned to your email address still has inter-letter
spaces. See how the attribution text (see at the very beginning of this
email) spells your name with your email address? That name comes from
the From: header of your email, which is set by either your email client
or, if you are using Google's web interface, your Google username.
P.S. You forgot to CC vim-dev list. I'm appending your original email
with this email for posterity; see below after the marker for forwarded
message.
===== Begin forwarded message =====
Date: Sat, 10 Dec 2022 10:16:19 +0100
From: N i c o l a s I I T h e B l o o d y <
niva...@gmail.com>
To: Enan Ajmain <
3nan....@gmail.com>
Subject: Re: Profile Cursor move (very slow)
I mean when i open 'tagbar.vim' in vim, about 4500 lines code.
I feel that the pb comes from the call of executable 'ctags': when you
move Cursor vertically from top to down, it pass through several
functions, and tagbar wants to show current function Cursor is in. So
it calls many times 'ctags executable' and this is causes delay on my
win11 Os.
I am currently trying to port tagbar legacy to vim9script. But if i am
right, the pb will still be there.
I have noticed your advise Enan.
Thank
Nicolas
Le sam. 10 déc. 2022 à 06:07, Enan Ajmain <
3nan....@gmail.com> a
écrit :
===== End forwarded message =====