Mercurial > vim
diff src/vim9compile.c @ 21034:2f8b0812819f v8.2.1068
patch 8.2.1068: Vim9: no line break allowed inside a dict
Commit: https://github.com/vim/vim/commit/8ea9390b78da9e34a20e7418712921397c0c1989
Author: Bram Moolenaar <Bram@vim.org>
Date: Sat Jun 27 14:11:53 2020 +0200
patch 8.2.1068: Vim9: no line break allowed inside a dict
Problem: Vim9: no line break allowed inside a dict.
Solution: Handle line break inside a dict in Vim9 script.
author | Bram Moolenaar <Bram@vim.org> |
---|---|
date | Sat, 27 Jun 2020 14:15:04 +0200 |
parents | 7acceb76669f |
children | d9e0db9b2b99 |
line wrap: on
line diff
--- a/src/vim9compile.c +++ b/src/vim9compile.c @@ -2996,7 +2996,7 @@ to_name_const_end(char_u *arg) { // Can be "#{a: 1}->Func()". ++p; - if (eval_dict(&p, &rettv, 0, TRUE) == FAIL) + if (eval_dict(&p, &rettv, NULL, TRUE) == FAIL) p = arg; } else if (p == arg && *arg == '{') @@ -3006,7 +3006,7 @@ to_name_const_end(char_u *arg) // Can be "{x -> ret}()". // Can be "{'a': 1}->Func()". if (ret == NOTDONE) - ret = eval_dict(&p, &rettv, 0, FALSE); + ret = eval_dict(&p, &rettv, NULL, FALSE); if (ret != OK) p = arg; }