aboutsummaryrefslogtreecommitdiff
path: root/src/nvim/eval/typval.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/nvim/eval/typval.c')
-rw-r--r--src/nvim/eval/typval.c36
1 files changed, 18 insertions, 18 deletions
diff --git a/src/nvim/eval/typval.c b/src/nvim/eval/typval.c
index 55dcfcc198..6a93b20345 100644
--- a/src/nvim/eval/typval.c
+++ b/src/nvim/eval/typval.c
@@ -991,7 +991,7 @@ const char *tv_list_find_str(list_T *const l, const int n)
{
const listitem_T *const li = tv_list_find(l, n);
if (li == NULL) {
- emsgf(_(e_listidx), (int64_t)n);
+ EMSG2(_(e_listidx), (int64_t)n);
return NULL;
}
return tv_get_string(TV_LIST_ITEM_TV(li));
@@ -1532,7 +1532,7 @@ bool tv_dict_get_callback(dict_T *const d,
}
if (!tv_is_func(di->di_tv) && di->di_tv.v_type != VAR_STRING) {
- emsgf(_("E6000: Argument is not a function or function name"));
+ EMSG(_("E6000: Argument is not a function or function name"));
return false;
}
@@ -2298,7 +2298,7 @@ void tv_item_lock(typval_T *const tv, const int deep, const bool lock)
static int recurse = 0;
if (recurse >= DICT_MAXNEST) {
- emsgf(_("E743: variable nested too deep for (un)lock"));
+ EMSG(_("E743: variable nested too deep for (un)lock"));
return;
}
if (deep == 0) {
@@ -2546,28 +2546,28 @@ bool tv_check_str_or_nr(const typval_T *const tv)
return true;
}
case VAR_FLOAT: {
- emsgf(_("E805: Expected a Number or a String, Float found"));
+ EMSG(_("E805: Expected a Number or a String, Float found"));
return false;
}
case VAR_PARTIAL:
case VAR_FUNC: {
- emsgf(_("E703: Expected a Number or a String, Funcref found"));
+ EMSG(_("E703: Expected a Number or a String, Funcref found"));
return false;
}
case VAR_LIST: {
- emsgf(_("E745: Expected a Number or a String, List found"));
+ EMSG(_("E745: Expected a Number or a String, List found"));
return false;
}
case VAR_DICT: {
- emsgf(_("E728: Expected a Number or a String, Dictionary found"));
+ EMSG(_("E728: Expected a Number or a String, Dictionary found"));
return false;
}
case VAR_SPECIAL: {
- emsgf(_("E5300: Expected a Number or a String"));
+ EMSG(_("E5300: Expected a Number or a String"));
return false;
}
case VAR_UNKNOWN: {
- emsgf(_(e_intern2), "tv_check_str_or_nr(UNKNOWN)");
+ EMSG2(_(e_intern2), "tv_check_str_or_nr(UNKNOWN)");
return false;
}
}
@@ -2611,7 +2611,7 @@ bool tv_check_num(const typval_T *const tv)
case VAR_DICT:
case VAR_FLOAT:
case VAR_UNKNOWN: {
- emsgf(_(num_errors[tv->v_type]));
+ EMSG(_(num_errors[tv->v_type]));
return false;
}
}
@@ -2655,7 +2655,7 @@ bool tv_check_str(const typval_T *const tv)
case VAR_DICT:
case VAR_FLOAT:
case VAR_UNKNOWN: {
- emsgf(_(str_errors[tv->v_type]));
+ EMSG(_(str_errors[tv->v_type]));
return false;
}
}
@@ -2702,7 +2702,7 @@ varnumber_T tv_get_number_chk(const typval_T *const tv, bool *const ret_error)
case VAR_LIST:
case VAR_DICT:
case VAR_FLOAT: {
- emsgf(_(num_errors[tv->v_type]));
+ EMSG(_(num_errors[tv->v_type]));
break;
}
case VAR_NUMBER: {
@@ -2778,23 +2778,23 @@ float_T tv_get_float(const typval_T *const tv)
}
case VAR_PARTIAL:
case VAR_FUNC: {
- emsgf(_("E891: Using a Funcref as a Float"));
+ EMSG(_("E891: Using a Funcref as a Float"));
break;
}
case VAR_STRING: {
- emsgf(_("E892: Using a String as a Float"));
+ EMSG(_("E892: Using a String as a Float"));
break;
}
case VAR_LIST: {
- emsgf(_("E893: Using a List as a Float"));
+ EMSG(_("E893: Using a List as a Float"));
break;
}
case VAR_DICT: {
- emsgf(_("E894: Using a Dictionary as a Float"));
+ EMSG(_("E894: Using a Dictionary as a Float"));
break;
}
case VAR_SPECIAL: {
- emsgf(_("E907: Using a special value as a Float"));
+ EMSG(_("E907: Using a special value as a Float"));
break;
}
case VAR_UNKNOWN: {
@@ -2840,7 +2840,7 @@ const char *tv_get_string_buf_chk(const typval_T *const tv, char *const buf)
case VAR_DICT:
case VAR_FLOAT:
case VAR_UNKNOWN: {
- emsgf(_(str_errors[tv->v_type]));
+ EMSG(_(str_errors[tv->v_type]));
return false;
}
}