mirror of
https://github.com/vim/vim.git
synced 2025-09-23 03:43:49 -04:00
patch 8.2.1479: Vim9: error for list index uses wrong line number
Problem: Vim9: error for list index uses wrong line number. Solution: Set source line number. (closes #6724) Add a way to assert the line number of the error with assert_fails().
This commit is contained in:
@@ -2299,6 +2299,7 @@ call_def_function(
|
||||
|
||||
ectx.ec_stack.ga_len -= is_slice ? 2 : 1;
|
||||
tv = STACK_TV_BOT(-1);
|
||||
SOURCING_LNUM = iptr->isn_lnum;
|
||||
if (list_slice_or_index(list, is_slice, n1, n2, tv, TRUE)
|
||||
== FAIL)
|
||||
goto on_error;
|
||||
|
Reference in New Issue
Block a user