patch 8.2.1996: Vim9: invalid error for argument of extend()
Problem: Vim9: invalid error for argument of extend().
Solution: Check if the type could match. (closes #7299)
diff --git a/src/proto/vim9compile.pro b/src/proto/vim9compile.pro
index 49213c8..fbee55c 100644
--- a/src/proto/vim9compile.pro
+++ b/src/proto/vim9compile.pro
@@ -1,6 +1,7 @@
/* vim9compile.c */
int check_defined(char_u *p, size_t len, cctx_T *cctx);
int check_compare_types(exptype_T type, typval_T *tv1, typval_T *tv2);
+int use_typecheck(type_T *actual, type_T *expected);
int get_script_item_idx(int sid, char_u *name, int check_writable, cctx_T *cctx);
imported_T *find_imported(char_u *name, size_t len, cctx_T *cctx);
imported_T *find_imported_in_script(char_u *name, size_t len, int sid);
diff --git a/src/proto/vim9type.pro b/src/proto/vim9type.pro
index e80f303..90f2345 100644
--- a/src/proto/vim9type.pro
+++ b/src/proto/vim9type.pro
@@ -15,6 +15,7 @@
void type_mismatch(type_T *expected, type_T *actual);
void arg_type_mismatch(type_T *expected, type_T *actual, int argidx);
int check_type(type_T *expected, type_T *actual, int give_msg, int argidx);
+int check_arg_type(type_T *expected, type_T *actual, int argidx);
char_u *skip_type(char_u *start, int optional);
type_T *parse_type(char_u **arg, garray_T *type_gap);
void common_type(type_T *type1, type_T *type2, type_T **dest, garray_T *type_gap);