OK, makes sense, thanks.
> On 18 Feb 2022, at 11:29, Bram Moolenaar wrote:
>
>
>>> Wether a function is script-local or global (when not using a "s:" or
>>> "g:" prefix) depends on the script it's defined in The rule is "at the
>>> script level, the type of script defines what the scope of the
> > Wether a function is script-local or global (when not using a "s:" or
> > "g:" prefix) depends on the script it's defined in The rule is "at the
> > script level, the type of script defines what the scope of the items
> > is". I think that's easy to understand.
>
> You know, I think the oth
> Wether a function is script-local or global (when not using a "s:" or
"g:" prefix) depends on the script it's defined in
> The rule is "at the script level, the type of script defines what the
scope of the items is". I think that's easy to understand.
You know, I think the other rule is argu
Maxim Kim wrote:
> Shouldn't def functions be prohibited in legacy vimscript?
>
> https://vi.stackexchange.com/questions/36829/how-can-i-define-vim9-functions-and-vim9-lambdas-in-a-vim9-script
>
> Basically if you add
>
> def! Hello()
> echo "hello world"
> enddef
>
> to a regular legacy
Shouldn't def functions be prohibited in legacy vimscript?
https://vi.stackexchange.com/questions/36829/how-can-i-define-vim9-functions-and-vim9-lambdas-in-a-vim9-script
Basically if you add
def! Hello()
echo "hello world"
enddef
to a regular legacy vim file (.vimrc, for example), function