diff src/vim9compile.c @ 21805:fdd58acef1cc v8.2.1452

patch 8.2.1452: Vim9: dead code in to_name_end() Commit: https://github.com/vim/vim/commit/8d56622944d563a79676e99532bd372b2bc6fa1f Author: Bram Moolenaar <Bram@vim.org> Date: Fri Aug 14 21:42:54 2020 +0200 patch 8.2.1452: Vim9: dead code in to_name_end() Problem: Vim9: dead code in to_name_end(). Solution: Remove check for lambda and dict, it won't be used.
author Bram Moolenaar <Bram@vim.org>
date Fri, 14 Aug 2020 21:45:04 +0200
parents f84625b961a8
children 15ed135796fd
line wrap: on
line diff
--- a/src/vim9compile.c
+++ b/src/vim9compile.c
@@ -2396,17 +2396,6 @@ to_name_const_end(char_u *arg)
 	if (eval_dict(&p, &rettv, NULL, TRUE) == FAIL)
 	    p = arg;
     }
-    else if (p == arg && *arg == '{')
-    {
-	int	    ret = get_lambda_tv(&p, &rettv, NULL);
-
-	// Can be "{x -> ret}()".
-	// Can be "{'a': 1}->Func()".
-	if (ret == NOTDONE)
-	    ret = eval_dict(&p, &rettv, NULL, FALSE);
-	if (ret != OK)
-	    p = arg;
-    }
 
     return p;
 }