0
0
mirror of https://github.com/vim/vim.git synced 2025-09-29 04:34:16 -04:00

patch 8.2.4934: string interpolation fails when not evaluating

Problem:    String interpolation fails when not evaluating.
Solution:   Skip the expression when not evaluating. (closes #10398)
This commit is contained in:
Bram Moolenaar
2022-05-10 18:11:43 +01:00
parent df6e0e46c5
commit 70c41241c2
5 changed files with 24 additions and 11 deletions

View File

@@ -2363,7 +2363,7 @@ eval_interp_string(char_u **arg, typval_T *rettv, int evaluate)
++*arg;
break;
}
p = eval_one_expr_in_str(*arg, &ga);
p = eval_one_expr_in_str(*arg, &ga, evaluate);
if (p == NULL)
{
ret = FAIL;