Mercurial > vim
comparison src/textprop.c @ 30015:adb0de8be4ce v9.0.0345
patch 9.0.0345: error message for list argument could be clearer
Commit: https://github.com/vim/vim/commit/d83392a43a48c566c0f3b76382a3648584dae32b
Author: Bram Moolenaar <Bram@vim.org>
Date: Thu Sep 1 12:22:46 2022 +0100
patch 9.0.0345: error message for list argument could be clearer
Problem: Error message for list argument could be clearer.
Solution: Include the argument number. (Yegappan Lakshmanan, closes https://github.com/vim/vim/issues/11027)
author | Bram Moolenaar <Bram@vim.org> |
---|---|
date | Thu, 01 Sep 2022 13:30:05 +0200 |
parents | 86eb4aba16c3 |
children | ed6f3d2593df |
comparison
equal
deleted
inserted
replaced
30014:3fb163e2ef6c | 30015:adb0de8be4ce |
---|---|
346 | 346 |
347 if (check_for_dict_arg(argvars, 0) == FAIL | 347 if (check_for_dict_arg(argvars, 0) == FAIL |
348 || check_for_list_arg(argvars, 1) == FAIL) | 348 || check_for_list_arg(argvars, 1) == FAIL) |
349 return; | 349 return; |
350 | 350 |
351 if (argvars[1].vval.v_list == NULL) | 351 if (check_for_nonnull_list_arg(argvars, 1) == FAIL) |
352 { | 352 return; |
353 emsg(_(e_list_required)); | |
354 return; | |
355 } | |
356 | 353 |
357 dict = argvars[0].vval.v_dict; | 354 dict = argvars[0].vval.v_dict; |
358 if (dict == NULL || !dict_has_key(dict, "type")) | 355 if (dict == NULL || !dict_has_key(dict, "type")) |
359 { | 356 { |
360 emsg(_(e_missing_property_type_name)); | 357 emsg(_(e_missing_property_type_name)); |