aboutsummaryrefslogtreecommitdiff
path: root/src/nvim/eval.c
diff options
context:
space:
mode:
authorLuuk van Baal <luukvbaal@gmail.com>2025-01-07 14:20:45 +0100
committerLuuk van Baal <luukvbaal@gmail.com>2025-01-09 13:35:40 +0100
commitead5683ff9994c0fbfc6c38e0911d9455777550b (patch)
treeaf8d0e65f3640393077202bbf44a57da7199ac76 /src/nvim/eval.c
parentb67fcd0488746b079a3b721ae4800af94cd126e1 (diff)
downloadrneovim-ead5683ff9994c0fbfc6c38e0911d9455777550b.tar.gz
rneovim-ead5683ff9994c0fbfc6c38e0911d9455777550b.tar.bz2
rneovim-ead5683ff9994c0fbfc6c38e0911d9455777550b.zip
feat(api): add err field to nvim_echo() opts
Problem: We want to deprecate `nvim_err_write(ln)()` but there is no obvious replacement (from Lua). Meanwhile we already have `nvim_echo()` with an `opts` argument. Solution: Add `err` argument to `nvim_echo()` that directly maps to `:echoerr`.
Diffstat (limited to 'src/nvim/eval.c')
-rw-r--r--src/nvim/eval.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/src/nvim/eval.c b/src/nvim/eval.c
index a90f275713..5b91f1248f 100644
--- a/src/nvim/eval.c
+++ b/src/nvim/eval.c
@@ -7968,8 +7968,7 @@ void ex_execute(exarg_T *eap)
} else if (eap->cmdidx == CMD_echoerr) {
// We don't want to abort following commands, restore did_emsg.
int save_did_emsg = did_emsg;
- msg_ext_set_kind("echoerr");
- emsg_multiline(ga.ga_data, true);
+ emsg_multiline(ga.ga_data, "echoerr", HLF_E, true);
if (!force_abort) {
did_emsg = save_did_emsg;
}