0
0
mirror of https://github.com/vim/vim.git synced 2025-11-15 23:14:06 -05:00

patch 8.2.1255: cannot use a lambda with quickfix functions

Problem:    Cannot use a lambda with quickfix functions.
Solution:   Add support for lambda. (Yegappan Lakshmanan, closes #6499)
This commit is contained in:
Bram Moolenaar
2020-07-20 21:31:32 +02:00
parent 470adb827f
commit d43906d2e5
11 changed files with 224 additions and 57 deletions

View File

@@ -1101,27 +1101,6 @@ channel_open(
return channel;
}
/*
* Copy callback from "src" to "dest", incrementing the refcounts.
*/
static void
copy_callback(callback_T *dest, callback_T *src)
{
dest->cb_partial = src->cb_partial;
if (dest->cb_partial != NULL)
{
dest->cb_name = src->cb_name;
dest->cb_free_name = FALSE;
++dest->cb_partial->pt_refcount;
}
else
{
dest->cb_name = vim_strsave(src->cb_name);
dest->cb_free_name = TRUE;
func_ref(src->cb_name);
}
}
static void
free_set_callback(callback_T *cbp, callback_T *callback)
{