Thursday, July 8, 2021

Re: Help converting function to Vim9 script

On 2021-07-07, lgc <jdupont655@gmail.com> wrote:
>> Any idea what would be the best way to convert the snippet above?
>
> Move the `i` variable in the script-local namespace.

Thanks for the thorough explanation. For now, I am keeping a function
instead of a def. But, as you say:

> FWIW, I would still refactor the code in Vim9. Mainly because of type
> checking, and for better readability.

I'll likely do that, using a script variable as you suggest.

Thanks,
Life.

--
--
You received this message from the "vim_use" 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_use" group.
To unsubscribe from this group and stop receiving emails from it, send an email to vim_use+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/vim_use/sc6u3t%2411j9%241%40ciao.gmane.io.

No comments:

Post a Comment