mirror of
https://github.com/neovim/neovim.git
synced 2025-09-25 04:28:33 +00:00
eval/encode: Do translate “… argument” strings, but only in conv_error
This commit is contained in:
@@ -179,7 +179,7 @@ static int conv_error(const char *const msg, const MPConvStack *const mpstack,
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
EMSG3(msg, objname, (kv_size(*mpstack) == 0
|
emsgf(msg, _(objname), (kv_size(*mpstack) == 0
|
||||||
? _("itself")
|
? _("itself")
|
||||||
: (char *)msg_ga.ga_data));
|
: (char *)msg_ga.ga_data));
|
||||||
ga_clear(&msg_ga);
|
ga_clear(&msg_ga);
|
||||||
@@ -790,7 +790,7 @@ char *encode_tv2string(typval_T *tv, size_t *len)
|
|||||||
garray_T ga;
|
garray_T ga;
|
||||||
ga_init(&ga, (int)sizeof(char), 80);
|
ga_init(&ga, (int)sizeof(char), 80);
|
||||||
const int evs_ret = encode_vim_to_string(&ga, tv,
|
const int evs_ret = encode_vim_to_string(&ga, tv,
|
||||||
"encode_tv2string() argument");
|
N_("encode_tv2string() argument"));
|
||||||
(void)evs_ret;
|
(void)evs_ret;
|
||||||
assert(evs_ret == OK);
|
assert(evs_ret == OK);
|
||||||
did_echo_string_emsg = false;
|
did_echo_string_emsg = false;
|
||||||
@@ -818,7 +818,7 @@ char *encode_tv2echo(typval_T *tv, size_t *len)
|
|||||||
ga_concat(&ga, tv->vval.v_string);
|
ga_concat(&ga, tv->vval.v_string);
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
const int eve_ret = encode_vim_to_echo(&ga, tv, ":echo argument");
|
const int eve_ret = encode_vim_to_echo(&ga, tv, N_(":echo argument"));
|
||||||
(void)eve_ret;
|
(void)eve_ret;
|
||||||
assert(eve_ret == OK);
|
assert(eve_ret == OK);
|
||||||
}
|
}
|
||||||
@@ -841,7 +841,8 @@ char *encode_tv2json(typval_T *tv, size_t *len)
|
|||||||
{
|
{
|
||||||
garray_T ga;
|
garray_T ga;
|
||||||
ga_init(&ga, (int)sizeof(char), 80);
|
ga_init(&ga, (int)sizeof(char), 80);
|
||||||
const int evj_ret = encode_vim_to_json(&ga, tv, "encode_tv2json() argument");
|
const int evj_ret = encode_vim_to_json(&ga, tv,
|
||||||
|
N_("encode_tv2json() argument"));
|
||||||
if (!evj_ret) {
|
if (!evj_ret) {
|
||||||
ga_clear(&ga);
|
ga_clear(&ga);
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user