mirror of
https://github.com/vim/vim.git
synced 2025-09-25 03:54:15 -04:00
patch 9.0.2038: Vim9: object method funcref not cleaned up after use
Problem: Vim9: object method funcref not cleaned up after use Solution: Clean up type stack after using object method funcref, remove now longer used ISN_DEFEROBJ instrunction closes: #13360 Signed-off-by: Christian Brabandt <cb@256bit.org> Co-authored-by: Yegappan Lakshmanan <yegappan@yahoo.com>
This commit is contained in:
committed by
Christian Brabandt
parent
209ec90b9b
commit
f3eac695bf
@@ -450,9 +450,9 @@ compile_class_object_index(cctx_T *cctx, char_u **arg, type_T *type)
|
||||
return FAIL;
|
||||
}
|
||||
*arg = name_end;
|
||||
if (type->tt_type == VAR_OBJECT)
|
||||
return generate_FUNCREF(cctx, fp, cl, TRUE, m_idx, NULL);
|
||||
return generate_FUNCREF(cctx, fp, NULL, FALSE, 0, NULL);
|
||||
// Remove the object type from the stack
|
||||
--cctx->ctx_type_stack.ga_len;
|
||||
return generate_FUNCREF(cctx, fp, cl, TRUE, m_idx, NULL);
|
||||
}
|
||||
|
||||
member_not_found_msg(cl, VAR_OBJECT, name, len);
|
||||
@@ -490,9 +490,9 @@ compile_class_object_index(cctx_T *cctx, char_u **arg, type_T *type)
|
||||
return FAIL;
|
||||
}
|
||||
*arg = name_end;
|
||||
if (type->tt_type == VAR_CLASS)
|
||||
return generate_FUNCREF(cctx, fp, cl, FALSE, m_idx, NULL);
|
||||
return generate_FUNCREF(cctx, fp, NULL, FALSE, 0, NULL);
|
||||
// Remove the class type from the stack
|
||||
--cctx->ctx_type_stack.ga_len;
|
||||
return generate_FUNCREF(cctx, fp, cl, FALSE, m_idx, NULL);
|
||||
}
|
||||
|
||||
member_not_found_msg(cl, VAR_CLASS, name, len);
|
||||
|
Reference in New Issue
Block a user