patch 8.2.2540: Vim9: no error for using script var name for argument
Problem: Vim9: no error for using script var name for argument.
Solution: Check for this error. (closes #7868)
diff --git a/src/vim9compile.c b/src/vim9compile.c
index c9591ad..0be2b29 100644
--- a/src/vim9compile.c
+++ b/src/vim9compile.c
@@ -337,7 +337,7 @@
* "cctx" is NULL at the script level.
* Returns OK or FAIL.
*/
- static int
+ int
script_var_exists(char_u *name, size_t len, int vim9script, cctx_T *cctx)
{
int is_vim9_script;