You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When the fix for #186 acts (i.e. when sneak-streak is activated in a buffer that has foldmethod=syntax), it stores "syntax" in s:fdm_orig in the s:before() function.
This is unconditionally restored in s:after() so that any buffer where you run sneak-streak after this has happened will have its foldmethod set to "syntax".
repo:
# Open a large buffer
vim src/nvim/fold.c
:set foldmethod=syntax
snvd
:vert help help
:set foldmethod=manual
swid
:set foldmethod?
I guess this could either be fixed by unconditionally setting s:fdm_orig to &l:foldmethod in s:before() or by putting a condition on setting foldmethod in s:after().
The text was updated successfully, but these errors were encountered:
FWIW this shouldn't happen with Vim 7.4.792 or Nvim 0.2 since c2cbcf7
But it still needs to be fixed for older versions.
justinmk
changed the title
Fix for #186 sometimes sets foldmethod when it shouldn't
'foldmethod' sometimes not restored (Vim 7.4.791 or older)
Aug 29, 2018
justinmk
changed the title
'foldmethod' sometimes not restored (Vim 7.4.791 or older)
label-mode (Vim 7.4.791 or older): 'foldmethod' sometimes not restored
Jan 31, 2020
Hi there,
When the fix for #186 acts (i.e. when sneak-streak is activated in a buffer that has
foldmethod=syntax
), it stores"syntax"
ins:fdm_orig
in thes:before()
function.This is unconditionally restored in
s:after()
so that any buffer where you run sneak-streak after this has happened will have itsfoldmethod
set to"syntax"
.repo:
I guess this could either be fixed by unconditionally setting
s:fdm_orig
to&l:foldmethod
ins:before()
or by putting a condition on settingfoldmethod
ins:after()
.The text was updated successfully, but these errors were encountered: