tyru / current-func-info.vim

Get current function name
http://www.vim.org/scripts/script.php?script_id=3197
62 stars 14 forks source link

Vim died of this plugin #26

Closed mingsxs closed 5 years ago

mingsxs commented 5 years ago

Sometimes this plugin just makes the vim died within my terminal. I was using this plugin on my C sources.

mingsxs commented 5 years ago

And when it happens, it will certainly happen when I try to do the same operation at the same place. whenever it is going with MacOS or Linux VIM.

tyru commented 5 years ago

You mean Vim died with segfault? If so, please file this issue on vim/vim after creating minimal code to reproduce.

GoldsteinE commented 5 years ago

Vim hangs forever with this plugin in lightline when I write

int main(

in C file.

GoldsteinE commented 5 years ago

I assume that problem is in this loop: https://github.com/tyru/current-func-info.vim/blob/master/ftplugin/c/cfi.vim#L36

GoldsteinE commented 5 years ago

When cursor is here:

int main(
        ^

condition

!empty(synstack(line('.'), col('.')))

is true, so it loops forever.

mnishz commented 5 years ago

Can anyone try the latest code? This issue should be also fixed. Thank you.

tyru commented 5 years ago

If a problem still persists, please reopen this.