mirror of
https://github.com/neovim/neovim.git
synced 2025-09-13 06:48:17 +00:00
vim-patch:8.1.1705: using ~{} for a literal dict is not nice
Problem: Using ~{} for a literal dict is not nice.
Solution: Use #{} instead.
4c6d90458b
This commit is contained in:
@@ -3906,7 +3906,7 @@ static int eval6(char_u **arg, typval_T *rettv, int evaluate, int want_string)
|
||||
// (expression) nested expression
|
||||
// [expr, expr] List
|
||||
// {key: val, key: val} Dictionary
|
||||
// ~{key: val, key: val} Dictionary with literal keys
|
||||
// #{key: val, key: val} Dictionary with literal keys
|
||||
//
|
||||
// Also handle:
|
||||
// ! in front logical NOT
|
||||
@@ -4014,8 +4014,8 @@ static int eval7(
|
||||
case '[': ret = get_list_tv(arg, rettv, evaluate);
|
||||
break;
|
||||
|
||||
// Dictionary: ~{key: val, key: val}
|
||||
case '~':
|
||||
// Dictionary: #{key: val, key: val}
|
||||
case '#':
|
||||
if ((*arg)[1] == '{') {
|
||||
(*arg)++;
|
||||
ret = dict_get_tv(arg, rettv, evaluate, true);
|
||||
|
Reference in New Issue
Block a user