Mercurial > vim
comparison src/testdir/test_autocmd.vim @ 31263:d8e7d725a666 v9.0.0965
patch 9.0.0965: using one window for executing autocommands is insufficient
Commit: https://github.com/vim/vim/commit/e76062c078debed0df818f70e4db14ad7a7cb53a
Author: Bram Moolenaar <Bram@vim.org>
Date: Mon Nov 28 18:51:43 2022 +0000
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.
author | Bram Moolenaar <Bram@vim.org> |
---|---|
date | Mon, 28 Nov 2022 20:00:05 +0100 |
parents | 684e6dfa2fba |
children | 49bd0e97549d |
comparison
equal
deleted
inserted
replaced
31262:7f766b7e17d5 | 31263:d8e7d725a666 |
---|---|
4066 delfunc Xautocmd_changelist | 4066 delfunc Xautocmd_changelist |
4067 bwipe! Xerr | 4067 bwipe! Xerr |
4068 call delete('Xerr') | 4068 call delete('Xerr') |
4069 endfunc | 4069 endfunc |
4070 | 4070 |
4071 " This was crashing because there was only one window to execute autocommands | |
4072 " in. | |
4073 func Test_autocmd_nested_setbufvar() | |
4074 CheckFeature python3 | |
4075 | |
4076 set hidden | |
4077 edit Xaaa | |
4078 edit Xbbb | |
4079 call setline(1, 'bar') | |
4080 enew | |
4081 au BufWriteCmd Xbbb ++nested call setbufvar('Xaaa', '&ft', 'foo') | bw! Xaaa | |
4082 au FileType foo call py3eval('vim.current.buffer.options["cindent"]') | |
4083 wall | |
4084 | |
4085 au! BufWriteCmd | |
4086 au! FileType foo | |
4087 set nohidden | |
4088 call delete('Xaaa') | |
4089 call delete('Xbbb') | |
4090 %bwipe! | |
4091 endfunc | |
4092 | |
4093 | |
4071 " vim: shiftwidth=2 sts=2 expandtab | 4094 " vim: shiftwidth=2 sts=2 expandtab |