comparison src/vim9expr.c @ 28852:ffd57385eef8 v8.2.4949

patch 8.2.4949: Vim9: some code not covered by tests Commit: https://github.com/vim/vim/commit/31ad32a325cc31f0f2bdd530c68bfb856a2187c5 Author: Bram Moolenaar <Bram@vim.org> Date: Fri May 13 16:23:37 2022 +0100 patch 8.2.4949: Vim9: some code not covered by tests Problem: Vim9: some code not covered by tests. Solution: Add a few more test cases. Fix double error message.
author Bram Moolenaar <Bram@vim.org>
date Fri, 13 May 2022 17:30:02 +0200
parents 0541b9c09e21
children 2644e49d5147
comparison
equal deleted inserted replaced
28851:9b622f8fdfa0 28852:ffd57385eef8
1897 } 1897 }
1898 else 1898 else
1899 { 1899 {
1900 int fail; 1900 int fail;
1901 int save_len = cctx->ctx_ufunc->uf_lines.ga_len; 1901 int save_len = cctx->ctx_ufunc->uf_lines.ga_len;
1902 int prev_did_emsg = did_emsg;
1902 1903
1903 *paren = NUL; 1904 *paren = NUL;
1904 1905
1905 // instead of using LOADG for "import.Func" use PUSHFUNC 1906 // instead of using LOADG for "import.Func" use PUSHFUNC
1906 ++paren_follows_after_expr; 1907 ++paren_follows_after_expr;
1914 --paren_follows_after_expr; 1915 --paren_follows_after_expr;
1915 cctx->ctx_ufunc->uf_lines.ga_len = save_len; 1916 cctx->ctx_ufunc->uf_lines.ga_len = save_len;
1916 1917
1917 if (fail) 1918 if (fail)
1918 { 1919 {
1919 semsg(_(e_invalid_expression_str), pstart); 1920 if (did_emsg == prev_did_emsg)
1921 semsg(_(e_invalid_expression_str), pstart);
1920 return FAIL; 1922 return FAIL;
1921 } 1923 }
1922 } 1924 }
1923 1925
1924 // Compile the arguments. 1926 // Compile the arguments.