1
0
forked from aniani/vim

patch 8.0.0439: ":%argdel" gives an error for an empty arglist

Problem:    Using ":%argdel" while the argument list is already empty gives an
            error. (Pavol Juhas)
Solution:   Don't give an error. (closes #1546)
This commit is contained in:
Bram Moolenaar
2017-03-09 15:58:30 +01:00
parent 056f700031
commit 69a92fb5ae
3 changed files with 14 additions and 1 deletions

View File

@@ -6,6 +6,10 @@ func Test_argidx()
call assert_equal(2, argidx())
%argdelete
call assert_equal(0, argidx())
" doing it again doesn't result in an error
%argdelete
call assert_equal(0, argidx())
call assert_fails('2argdelete', 'E16:')
args a b c
call assert_equal(0, argidx())