diff src/proto/vim9type.pro @ 27171:374c7d5a096a v8.2.4114

patch 8.2.4114: Vim9: type checking for a funcref does not work for method Commit: https://github.com/vim/vim/commit/c84287d6d8dd055bb6e30605465a23a8addb6fde Author: Bram Moolenaar <Bram@vim.org> Date: Sun Jan 16 18:06:21 2022 +0000 patch 8.2.4114: Vim9: type checking for a funcref does not work for method Problem: Vim9: type checking for a funcref does not work for when it is used in a method. Solution: Pass the base to where the type is checked.
author Bram Moolenaar <Bram@vim.org>
date Sun, 16 Jan 2022 19:15:03 +0100
parents ccb9be1cdd71
children 4cea92e99a5a
line wrap: on
line diff
--- a/src/proto/vim9type.pro
+++ b/src/proto/vim9type.pro
@@ -12,12 +12,11 @@ type_T *typval2type(typval_T *tv, int co
 type_T *typval2type_vimvar(typval_T *tv, garray_T *type_gap);
 int check_typval_arg_type(type_T *expected, typval_T *actual_tv, char *func_name, int arg_idx);
 int check_typval_type(type_T *expected, typval_T *actual_tv, where_T where);
-void type_mismatch(type_T *expected, type_T *actual);
 void arg_type_mismatch(type_T *expected, type_T *actual, int arg_idx);
 void type_mismatch_where(type_T *expected, type_T *actual, where_T where);
 int check_type(type_T *expected, type_T *actual, int give_msg, where_T where);
 int check_type_maybe(type_T *expected, type_T *actual, int give_msg, where_T where);
-int check_argument_types(type_T *type, typval_T *argvars, int argcount, char_u *name);
+int check_argument_types(type_T *type, typval_T *argvars, int argcount, typval_T *base_tv, char_u *name);
 char_u *skip_type(char_u *start, int optional);
 type_T *parse_type(char_u **arg, garray_T *type_gap, int give_error);
 int equal_type(type_T *type1, type_T *type2, int flags);