patch 8.1.1588: in :let-heredoc line continuation is recognized
Problem: In :let-heredoc line continuation is recognized.
Solution: Do not consume line continuation. (Ozaki Kiichi, closes #4580)
diff --git a/src/userfunc.c b/src/userfunc.c
index be99313..864c816 100644
--- a/src/userfunc.c
+++ b/src/userfunc.c
@@ -2007,6 +2007,7 @@
hashtab_T *ht;
int todo;
hashitem_T *hi;
+ int do_concat = TRUE;
int sourcing_lnum_off;
/*
@@ -2303,9 +2304,9 @@
{
vim_free(line_to_free);
if (eap->getline == NULL)
- theline = getcmdline(':', 0L, indent);
+ theline = getcmdline(':', 0L, indent, do_concat);
else
- theline = eap->getline(':', eap->cookie, indent);
+ theline = eap->getline(':', eap->cookie, indent, do_concat);
line_to_free = theline;
}
if (KeyTyped)
@@ -2334,6 +2335,7 @@
{
VIM_CLEAR(skip_until);
VIM_CLEAR(trimmed);
+ do_concat = TRUE;
}
}
}
@@ -2458,6 +2460,7 @@
skip_until = vim_strsave((char_u *)".");
else
skip_until = vim_strnsave(p, (int)(skiptowhite(p) - p));
+ do_concat = FALSE;
}
}
@@ -3511,7 +3514,8 @@
get_func_line(
int c UNUSED,
void *cookie,
- int indent UNUSED)
+ int indent UNUSED,
+ int do_concat UNUSED)
{
funccall_T *fcp = (funccall_T *)cookie;
ufunc_T *fp = fcp->func;