kevinhwang91 / nvim-ufo

Not UFO in the sky, but an ultra fold in Neovim.
BSD 3-Clause "New" or "Revised" License
2.16k stars 37 forks source link

Crash on vsplit on large file (1k lines) #180

Closed serranomorante closed 7 months ago

serranomorante commented 7 months ago

Neovim version (nvim -v | head -n1)

nvim 0.10... dev

Operating system/version

arch linux

How to reproduce the issue

Same as #176

t-rec_35

Steps

  1. open this file
  2. fold everything with zM
  3. vsplit
  4. start to open folds

Expected behavior

don't crash

Actual behavior

crash

rockyzhang24 commented 7 months ago

On my end, it doesn't crash. But I encountered another issue (https://github.com/kevinhwang91/nvim-ufo/issues/181). Not sure if it's related to this issue.

https://github.com/kevinhwang91/nvim-ufo/assets/11582667/923f6890-e15f-464e-895e-eda1369767b7

serranomorante commented 7 months ago

On my end, it doesn't crash. But I encountered another issue (https://github.com/kevinhwang91/nvim-ufo/issues/181). Not sure if it's related to this issue.

https://github.com/kevinhwang91/nvim-ufo/assets/11582667/923f6890-e15f-464e-895e-eda1369767b7

Hi! Thanks

Maybe if you stay on the left window (instead of moving to the split on the right) maybe that should make it crash. (That's the only difference I can see from my example)

I'm using a bare-bones nvim with latest ufo and promise-async and nothing else so I believe this is definitely reproducible.

rockyzhang24 commented 7 months ago

Maybe if you stay on the left window (instead of moving to the split on the right) maybe that should make it crash. (That's the only difference I can see from my example)

No. I turned on splitright in my vimrc so the right window is the new window after :vsplit. You're using the bare-bone nvim where splitright is off by default, so your left window is the new window. So we're in the same scenario and I cannot reproduce it.

Btw, my nvim version NVIM v0.10.0-dev-1627+g879617c9b that was builtin one hour ago with the latest master. My OS is macOS 14.1.1 (the latest). Not sure if it's system-related.