diff options
author | zeertzjq <zeertzjq@outlook.com> | 2022-12-04 16:29:36 +0800 |
---|---|---|
committer | zeertzjq <zeertzjq@outlook.com> | 2022-12-04 16:34:01 +0800 |
commit | d93b9062549662bfb9262967ac546291ccbc73be (patch) | |
tree | e076b35d34fe9a9f6edddc600af66a7254ceabf1 /src/nvim/testdir/test_autoload.vim | |
parent | 32810c0818bd0a602c8f790c3fcb1d67194978c8 (diff) | |
download | rneovim-d93b9062549662bfb9262967ac546291ccbc73be.tar.gz rneovim-d93b9062549662bfb9262967ac546291ccbc73be.tar.bz2 rneovim-d93b9062549662bfb9262967ac546291ccbc73be.zip |
vim-patch:8.2.4168: disallowing empty function name breaks existing plugins
Problem: Disallowing empty function name breaks existing plugins.
Solution: Allow empty function name in legacy script.
https://github.com/vim/vim/commit/e6a4200ff47708febcd7cb2b8c3dd3801a975d43
Co-authored-by: Bram Moolenaar <Bram@vim.org>
Diffstat (limited to 'src/nvim/testdir/test_autoload.vim')
-rw-r--r-- | src/nvim/testdir/test_autoload.vim | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/src/nvim/testdir/test_autoload.vim b/src/nvim/testdir/test_autoload.vim index b8c4fa251f..e89fe3943b 100644 --- a/src/nvim/testdir/test_autoload.vim +++ b/src/nvim/testdir/test_autoload.vim @@ -10,6 +10,9 @@ func Test_autoload_dict_func() call assert_equal(1, g:called_foo_bar_echo) eval 'bar'->g:foo#addFoo()->assert_equal('barfoo') + + " empty name works in legacy script + call assert_equal('empty', foo#()) endfunc func Test_source_autoload() @@ -17,3 +20,6 @@ func Test_source_autoload() source sautest/autoload/sourced.vim call assert_equal(1, g:loaded_sourced_vim) endfunc + + +" vim: shiftwidth=2 sts=2 expandtab |