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)
diff --git a/src/testdir/test_arglist.vim b/src/testdir/test_arglist.vim
index 0caead8..d18035b 100644
--- a/src/testdir/test_arglist.vim
+++ b/src/testdir/test_arglist.vim
@@ -6,6 +6,10 @@
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())