diff src/eval.c @ 17413:40417757dffd v8.1.1705

patch 8.1.1705: using ~{} for a literal dict is not nice commit https://github.com/vim/vim/commit/4c6d90458baae843463f930fdc3fe4a7a2191d27 Author: Bram Moolenaar <Bram@vim.org> Date: Tue Jul 16 22:04:02 2019 +0200 patch 8.1.1705: using ~{} for a literal dict is not nice Problem: Using ~{} for a literal dict is not nice. Solution: Use #{} instead.
author Bram Moolenaar <Bram@vim.org>
date Tue, 16 Jul 2019 22:15:05 +0200
parents 2558f90045e5
children f8cd16838434
line wrap: on
line diff
--- a/src/eval.c
+++ b/src/eval.c
@@ -4392,7 +4392,7 @@ eval6(
  *  (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
@@ -4577,9 +4577,9 @@ eval7(
 		break;
 
     /*
-     * Dictionary: ~{key: val, key: val}
+     * Dictionary: #{key: val, key: val}
      */
-    case '~':	if ((*arg)[1] == '{')
+    case '#':	if ((*arg)[1] == '{')
 		{
 		    ++*arg;
 		    ret = dict_get_tv(arg, rettv, evaluate, TRUE);
@@ -7963,8 +7963,7 @@ find_var_ht(char_u *name, char_u **varna
     *varname = name + 2;
     if (*name == 'g')				/* global variable */
 	return &globvarht;
-    /* There must be no ':' or '#' in the rest of the name, unless g: is used
-     */
+    // There must be no ':' or '#' in the rest of the name, unless g: is used
     if (vim_strchr(name + 2, ':') != NULL
 			       || vim_strchr(name + 2, AUTOLOAD_CHAR) != NULL)
 	return NULL;