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:
@@ -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
|
||||
|
||||
Reference in New Issue
Block a user