mirror of
https://github.com/vim/vim.git
synced 2025-09-29 04:34:16 -04:00
patch 9.0.1829: Vim9 missing access-checks for private vars
Problem: Vim9 missing access-checks for private vars Solution: Use the proper check for private/readonly variable. Access level for a member cannot be changed in a class implementing an interface. Update the code indentation closes: #12978 Signed-off-by: Christian Brabandt <cb@256bit.org> Co-authored-by: Yegappan Lakshmanan <yegappan@yahoo.com> Co-authored-by: Ernie Rael <errael@raelity.com>
This commit is contained in:
committed by
Christian Brabandt
parent
ac2d8815ae
commit
eb91e24d5e
@@ -539,7 +539,7 @@ check_for_list_arg(typval_T *args, int idx)
|
||||
{
|
||||
if (args[idx].v_type != VAR_LIST)
|
||||
{
|
||||
semsg(_(e_list_required_for_argument_nr), idx + 1);
|
||||
semsg(_(e_list_required_for_argument_nr), idx + 1);
|
||||
return FAIL;
|
||||
}
|
||||
return OK;
|
||||
@@ -981,7 +981,7 @@ check_for_object_arg(typval_T *args, int idx)
|
||||
{
|
||||
if (args[idx].v_type != VAR_OBJECT)
|
||||
{
|
||||
semsg(_(e_object_required_for_argument_nr), idx + 1);
|
||||
semsg(_(e_object_required_for_argument_nr), idx + 1);
|
||||
return FAIL;
|
||||
}
|
||||
return OK;
|
||||
@@ -995,7 +995,7 @@ check_for_class_or_list_arg(typval_T *args, int idx)
|
||||
{
|
||||
if (args[idx].v_type != VAR_CLASS && args[idx].v_type != VAR_LIST)
|
||||
{
|
||||
semsg(_(e_list_or_class_required_for_argument_nr), idx + 1);
|
||||
semsg(_(e_list_or_class_required_for_argument_nr), idx + 1);
|
||||
return FAIL;
|
||||
}
|
||||
return OK;
|
||||
|
Reference in New Issue
Block a user