1
0
forked from aniani/vim

patch 9.0.0965: using one window for executing autocommands is insufficient

Problem:    Using one window for executing autocommands is insufficient.
Solution:   Use up to five windows for executing autocommands.
This commit is contained in:
Bram Moolenaar
2022-11-28 18:51:43 +00:00
parent 74a694dbe2
commit e76062c078
28 changed files with 451 additions and 260 deletions

View File

@@ -4068,4 +4068,27 @@ func Test_autocmd_split_dummy()
call delete('Xerr')
endfunc
" This was crashing because there was only one window to execute autocommands
" in.
func Test_autocmd_nested_setbufvar()
CheckFeature python3
set hidden
edit Xaaa
edit Xbbb
call setline(1, 'bar')
enew
au BufWriteCmd Xbbb ++nested call setbufvar('Xaaa', '&ft', 'foo') | bw! Xaaa
au FileType foo call py3eval('vim.current.buffer.options["cindent"]')
wall
au! BufWriteCmd
au! FileType foo
set nohidden
call delete('Xaaa')
call delete('Xbbb')
%bwipe!
endfunc
" vim: shiftwidth=2 sts=2 expandtab