0
0
mirror of https://github.com/vim/vim.git synced 2025-09-23 03:43:49 -04:00

patch 8.2.0149: maintaining a Vim9 branch separately is more work

Problem:    Maintaining a Vim9 branch separately is more work.
Solution:   Merge the Vim9 script changes.
This commit is contained in:
Bram Moolenaar
2020-01-26 15:56:19 +01:00
parent 1d9215b9aa
commit 8a7d6542b3
65 changed files with 11777 additions and 1327 deletions

View File

@@ -58,24 +58,24 @@ rettv_blob_set(typval_T *rettv, blob_T *b)
}
int
blob_copy(typval_T *from, typval_T *to)
blob_copy(blob_T *from, typval_T *to)
{
int ret = OK;
to->v_type = VAR_BLOB;
to->v_lock = 0;
if (from->vval.v_blob == NULL)
if (from == NULL)
to->vval.v_blob = NULL;
else if (rettv_blob_alloc(to) == FAIL)
ret = FAIL;
else
{
int len = from->vval.v_blob->bv_ga.ga_len;
int len = from->bv_ga.ga_len;
if (len > 0)
{
to->vval.v_blob->bv_ga.ga_data =
vim_memsave(from->vval.v_blob->bv_ga.ga_data, len);
vim_memsave(from->bv_ga.ga_data, len);
if (to->vval.v_blob->bv_ga.ga_data == NULL)
len = 0;
}