diff src/vim.h @ 23495:1f85acfb23cd v8.2.2290

patch 8.2.2290: Vim9: unlet of global variable cannot be compiled Commit: https://github.com/vim/vim/commit/2ef951dd31505874ae9ac35a18513ef34ae0ea3e Author: Bram Moolenaar <Bram@vim.org> Date: Sun Jan 3 20:55:26 2021 +0100 patch 8.2.2290: Vim9: unlet of global variable cannot be compiled Problem: Vim9: unlet of global variable cannot be compiled. Solution: Skip over variables that might be defined later. Give an error if a subscript is found. (closes #7585)
author Bram Moolenaar <Bram@vim.org>
date Sun, 03 Jan 2021 21:00:05 +0100
parents a8e7acf71fa4
children cd06cc37f53f
line wrap: on
line diff
--- a/src/vim.h
+++ b/src/vim.h
@@ -2544,12 +2544,14 @@ typedef enum {
 #define TFN_NO_DEREF	0x08	// do not dereference a Funcref
 #define TFN_READ_ONLY	0x10	// will not change the var
 #define TFN_NO_DECL	0x20	// only used for GLV_NO_DECL
+#define TFN_COMPILING	0x40	// only used for GLV_COMPILING
 
 // Values for get_lval() flags argument:
 #define GLV_QUIET	TFN_QUIET	// no error messages
 #define GLV_NO_AUTOLOAD	TFN_NO_AUTOLOAD	// do not use script autoloading
 #define GLV_READ_ONLY	TFN_READ_ONLY	// will not change the var
 #define GLV_NO_DECL	TFN_NO_DECL	// assignment without :var or :let
+#define GLV_COMPILING	TFN_COMPILING	// variable may be defined later
 
 #define DO_NOT_FREE_CNT 99999	// refcount for dict or list that should not
 				// be freed.