diff options
author | Bram Moolenaar <Bram@vim.org> | 2020-11-30 21:12:19 +0100 |
---|---|---|
committer | Bram Moolenaar <Bram@vim.org> | 2020-11-30 21:12:19 +0100 |
commit | da7c20c9531739bdefa9d4418e6765fb181066e9 (patch) | |
tree | 6bf807f700477ff01a046ae0489f2888962970aa /src/ex_docmd.c | |
parent | f0068c5154a99b86b2c4515a4b93c003b2445cf4 (diff) | |
download | vim-git-da7c20c9531739bdefa9d4418e6765fb181066e9.tar.gz |
patch 8.2.2071: Vim9: list assign doesn't except empty remainder listv8.2.2071
Problem: Vim9: list assign doesn't except empty remainder list.
Solution: Recognize list assignment with ";".
Diffstat (limited to 'src/ex_docmd.c')
-rw-r--r-- | src/ex_docmd.c | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/src/ex_docmd.c b/src/ex_docmd.c index d530c0823..1d5d2dedc 100644 --- a/src/ex_docmd.c +++ b/src/ex_docmd.c @@ -3356,7 +3356,14 @@ find_ex_command( if (*eap->cmd == '[') { p = to_name_const_end(eap->cmd); - if (p == eap->cmd || *skipwhite(p) != '=') + if (p == eap->cmd && *p == '[') + { + int count = 0; + int semicolon = FALSE; + + p = skip_var_list(eap->cmd, TRUE, &count, &semicolon, TRUE); + } + if (p == NULL || p == eap->cmd || *skipwhite(p) != '=') { eap->cmdidx = CMD_eval; return eap->cmd; |