summaryrefslogtreecommitdiffstats
path: root/src/eval.c
diff options
context:
space:
mode:
authorBram Moolenaar <Bram@vim.org>2011-01-04 19:03:27 +0100
committerBram Moolenaar <Bram@vim.org>2011-01-04 19:03:27 +0100
commit6d0efdaab5d97684056598f0a38cc98d2568f8d7 (patch)
tree73900c24e2390b27192865fd895f0e3271f19a32 /src/eval.c
parent870b05c4c087980a14d180ea680cb0ff35d62331 (diff)
updated for version 7.3.097v7.3.097
Problem: Using ":call" inside "if 0" does not see that a function returns a Dict and gives error for "." as string concatenation. Solution: Use eval0() to skip over the expression. (Yasuhiro Matsumoto)
Diffstat (limited to 'src/eval.c')
-rw-r--r--src/eval.c9
1 files changed, 9 insertions, 0 deletions
diff --git a/src/eval.c b/src/eval.c
index 7d00c0e478..a73731198b 100644
--- a/src/eval.c
+++ b/src/eval.c
@@ -3335,6 +3335,15 @@ ex_call(eap)
int failed = FALSE;
funcdict_T fudi;
+ if (eap->skip)
+ {
+ /* trans_function_name() doesn't work well when skipping, use eval0()
+ * instead to skip to any following command, e.g. for:
+ * :if 0 | call dict.foo().bar() | endif */
+ eval0(eap->arg, &rettv, &eap->nextcmd, FALSE);
+ return;
+ }
+
tofree = trans_function_name(&arg, eap->skip, TFN_INT, &fudi);
if (fudi.fd_newkey != NULL)
{