Mercurial > vim
diff src/vim9compile.c @ 22614:048a3033d19c v8.2.1855
patch 8.2.1855: Vim9: get error message when nothing is wrong
Commit: https://github.com/vim/vim/commit/e13bdec6b90b3a0fce4f021e3ee986e731cea3b5
Author: Bram Moolenaar <Bram@vim.org>
Date: Fri Oct 16 23:16:47 2020 +0200
patch 8.2.1855: Vim9: get error message when nothing is wrong
Problem: Vim9: get error message when nothing is wrong.
Solution: Check called_emsg instead of did_emsg. (closes https://github.com/vim/vim/issues/7143)
author | Bram Moolenaar <Bram@vim.org> |
---|---|
date | Fri, 16 Oct 2020 23:30:03 +0200 |
parents | 336ac63fb987 |
children | 1064b9f05b0a |
line wrap: on
line diff
--- a/src/vim9compile.c +++ b/src/vim9compile.c @@ -6642,7 +6642,9 @@ compile_put(char_u *arg, exarg_T *eap, c else if (eap->regname != NUL) ++line; - // TODO: if the range is something like "$" need to evaluate at runtime + // "errormsg" will not be set because the range is ADDR_LINES. + // TODO: if the range contains something like "$" or "." need to evaluate + // at runtime if (parse_cmd_address(eap, &errormsg, FALSE) == FAIL) return NULL; if (eap->addr_count == 0) @@ -7399,7 +7401,7 @@ erret: if (errormsg != NULL) emsg(errormsg); else if (called_emsg == called_emsg_before) - emsg(_(e_compile_def_function_failed)); + emsg(_(e_compiling_def_function_failed)); } current_sctx = save_current_sctx;