Patch 8.2.4164 (after 8.2.4162)
Problem: Error in legacy code for function shadowing variable.
Solution: Only give the error in Vim9 script.
Files: src/userfunc.c
*** ../vim-8.2.4163/src/userfunc.c 2022-01-20 19:38:42.055859122 +0000
--- src/userfunc.c 2022-01-20 19:55:07.165536296 +0000
***************
*** 4466,4472 ****
int var_conflict = FALSE;
v = find_var(name, &ht, TRUE);
! if (v != NULL)
var_conflict = TRUE;
if (SCRIPT_ID_VALID(current_sctx.sc_sid))
--- 4466,4472 ----
int var_conflict = FALSE;
v = find_var(name, &ht, TRUE);
! if (v != NULL && (in_vim9script() || v->di_tv.v_type == VAR_FUNC))
var_conflict = TRUE;
if (SCRIPT_ID_VALID(current_sctx.sc_sid))
*** ../vim-8.2.4163/src/version.c 2022-01-20 19:38:42.055859122 +0000
--- src/version.c 2022-01-20 19:56:33.335896678 +0000
***************
*** 752,753 ****
--- 752,755 ----
{ /* Add new patch number below this line */
+ /**/
+ 4164,
/**/
--
Q: How do you tell the difference between a female cat and a male cat?
A: You ask it a question and if HE answers, it's a male but, if SHE
answers, it's a female.
/// Bram Moolenaar -- [email protected] -- http://www.Moolenaar.net \\\
/// \\\
\\\ sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ ///
\\\ help me help AIDS victims -- http://ICCF-Holland.org ///
--
--
You received this message from the "vim_dev" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php
---
You received this message because you are subscribed to the Google Groups
"vim_dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To view this discussion on the web visit
https://groups.google.com/d/msgid/vim_dev/20220120195719.C20BD1C188D%40moolenaar.net.