Given the vimscript code l:my_dict.my_key, using splitjoin's gS at the . character produces
When vim's scriptversion is 1 this creates ambiguity between dict key lookup and string concatenation due to the space between \ and .my_key. (The dot is an attractive split point when writing vim script with an object-oriented style: l:object.SomeMethod(arg, list).AnotherMethod(more, args).)
Vim seems to gracefully handle the \ .my_key ambiguity by checking if the type of l:my_dict is Dict, but NeoVim produces an E731: using Dictionary as a String error. :help expr-entry says "There must not be white space before or after the dot." It would be nice if splitting on a dot without space around it would result in a semantically identical split like
(note the lack of space in \.).
Given the vimscript code
l:my_dict.my_key, using splitjoin'sgSat the.character producesWhen vim's
scriptversionis1this creates ambiguity between dict key lookup and string concatenation due to the space between\and.my_key. (The dot is an attractive split point when writing vim script with an object-oriented style:l:object.SomeMethod(arg, list).AnotherMethod(more, args).)Vim seems to gracefully handle the
\ .my_keyambiguity by checking if the type ofl:my_dictis Dict, but NeoVim produces anE731: using Dictionary as a Stringerror.:help expr-entrysays "There must not be white space before or after the dot." It would be nice if splitting on a dot without space around it would result in a semantically identical split like(note the lack of space in
\.).