Hi,
On Wed, Mar 16, 2022 at 8:43 AM Yegappan Lakshmanan <[email protected]> wrote:
>
> Hi,
>
> With the recent changes to Vim9, I started seeing the
> "E1167: Argument name shadows existing variable" error with the LSP plugin.
>
> I am able to reproduce this error with the below sample script:
>
A minor update to the sample script is below:
--------------------------------------------------------------------------------------------
vim9script
def ProcessInitializeReply(lspserver: dict<any>)
enddef
def ProcessReply(lspserver: dict<any>)
var lsp_reply_handlers: dict<func> =
{
'initialize': ProcessInitializeReply
}
lsp_reply_handlers['initialize'](lspserver)
enddef
call ProcessReply({})
--------------------------------------------------------------------------------------------
>
> If you source the above script with the latest Vim, you will see the
> E1167 error.
>
> I don't see any problems with this usage. The arguments to the ProcessReply()
> and ProcessInititializeReply() functions are named "lspserver". But these
> are two separate functions. So I should be able to use the same name for
> the arguments.
>
> - Yegappan
--
--
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/CAAW7x7k-nDg%3DSh6dBkqiA20QpzGjm5fA1AkPBdy8qS%2BrigH3qw%40mail.gmail.com.