patch 8.2.4943: changing 'switchbuf' may have no effect
Problem: Changing 'switchbuf' may have no effect.
Solution: Handle 'switchbuf' in didset_string_options(). (Sean Dewar,
closes #10406)
diff --git a/src/testdir/test_options.vim b/src/testdir/test_options.vim
index 8854ffd..0a53315 100644
--- a/src/testdir/test_options.vim
+++ b/src/testdir/test_options.vim
@@ -1299,4 +1299,15 @@
set wildoptions=
endfunc
+func Test_switchbuf_reset()
+ set switchbuf=useopen
+ sblast
+ call assert_equal(1, winnr('$'))
+ set all&
+ call assert_equal('', &switchbuf)
+ sblast
+ call assert_equal(2, winnr('$'))
+ only!
+endfunc
+
" vim: shiftwidth=2 sts=2 expandtab