diff src/vim9execute.c @ 28152:b96409b84eaf v8.2.4600

patch 8.2.4600: Vim9: not enough test coverage for executing :def function Commit: https://github.com/vim/vim/commit/6b8c7ba062ca4b50e8f983e0485be7afa4eef691 Author: Bram Moolenaar <Bram@vim.org> Date: Sun Mar 20 17:46:06 2022 +0000 patch 8.2.4600: Vim9: not enough test coverage for executing :def function Problem: Vim9: not enough test coverage for executing :def function. Solution: Add a few more tests. Fix inconsistencies.
author Bram Moolenaar <Bram@vim.org>
date Sun, 20 Mar 2022 19:00:03 +0100
parents d8bf200cd761
children 088d8dc22045
line wrap: on
line diff
--- a/src/vim9execute.c
+++ b/src/vim9execute.c
@@ -2048,9 +2048,6 @@ execute_unletindex(isn_T *iptr, ectx_T *
 		    semsg(_(e_list_index_out_of_range_nr), n);
 		    status = FAIL;
 		}
-		else if (value_check_lock(li->li_tv.v_lock,
-						  NULL, FALSE))
-		    status = FAIL;
 		else
 		    listitem_remove(l, li);
 	    }
@@ -2133,11 +2130,9 @@ execute_unletrange(isn_T *iptr, ectx_T *
 		    semsg(_(e_list_index_out_of_range_nr), n2);
 		    status = FAIL;
 		}
-		if (status != FAIL
-			&& list_unlet_range(l, li, NULL, n1,
-			    tv_idx2->v_type != VAR_SPECIAL, n2)
-						       == FAIL)
-		    status = FAIL;
+		if (status != FAIL)
+		    list_unlet_range(l, li, n1,
+					   tv_idx2->v_type != VAR_SPECIAL, n2);
 	    }
 	}
     }