patch 8.2.3188: Vim9: argument types are not checked at compile time
Problem: Vim9: argument types are not checked at compile time.
Solution: Add several more type checks, also at runtime. (Yegappan
Lakshmanan, closes #8587)
diff --git a/src/proto/typval.pro b/src/proto/typval.pro
index ccde9a6..c673db3 100644
--- a/src/proto/typval.pro
+++ b/src/proto/typval.pro
@@ -11,10 +11,24 @@
float_T tv_get_float(typval_T *varp);
int check_for_string_arg(typval_T *args, int idx);
int check_for_nonempty_string_arg(typval_T *args, int idx);
+int check_for_opt_string_arg(typval_T *args, int idx);
int check_for_number_arg(typval_T *args, int idx);
+int check_for_opt_number_arg(typval_T *args, int idx);
int check_for_bool_arg(typval_T *args, int idx);
+int check_for_opt_bool_arg(typval_T *args, int idx);
int check_for_list_arg(typval_T *args, int idx);
+int check_for_opt_list_arg(typval_T *args, int idx);
int check_for_dict_arg(typval_T *args, int idx);
+int check_for_opt_dict_arg(typval_T *args, int idx);
+int check_for_blob_arg(typval_T *args, int idx);
+int check_for_chan_or_job_arg(typval_T *args, int idx);
+int check_for_job_arg(typval_T *args, int idx);
+int check_for_string_or_number_arg(typval_T *args, int idx);
+int check_for_buffer_arg(typval_T *args, int idx);
+int check_for_lnum_arg(typval_T *args, int idx);
+int check_for_opt_lnum_arg(typval_T *args, int idx);
+int check_for_opt_string_or_number_arg(typval_T *args, int idx);
+int check_for_string_or_blob_arg(typval_T *args, int idx);
char_u *tv_get_string(typval_T *varp);
char_u *tv_get_string_strict(typval_T *varp);
char_u *tv_get_string_buf(typval_T *varp, char_u *buf);