summaryrefslogtreecommitdiff
path: root/src/structs.h
diff options
context:
space:
mode:
authorBram Moolenaar <Bram@vim.org>2022-01-06 21:10:28 +0000
committerBram Moolenaar <Bram@vim.org>2022-01-06 21:10:28 +0000
commitd5f400c607182db6d4fbe2964471d796277f67e8 (patch)
tree285e08dceecf77069c17d1c513e3c918140b18dc /src/structs.h
parent18f4740f043b353abe47b7a00131317052457686 (diff)
downloadvim-git-d5f400c607182db6d4fbe2964471d796277f67e8.tar.gz
patch 8.2.4019: Vim9: import mechanism is too complicatedv8.2.4019
Problem: Vim9: import mechanism is too complicated. Solution: Do not use the Javascript mechanism but a much simpler one.
Diffstat (limited to 'src/structs.h')
-rw-r--r--src/structs.h15
1 files changed, 5 insertions, 10 deletions
diff --git a/src/structs.h b/src/structs.h
index 1a764e170..197df720c 100644
--- a/src/structs.h
+++ b/src/structs.h
@@ -1822,19 +1822,10 @@ struct svar_S {
typedef struct {
char_u *imp_name; // name imported as (allocated)
- int imp_sid; // script ID of "from"
-
+ scid_T imp_sid; // script ID of "from"
int imp_flags; // IMP_FLAGS_ values
-
- // for a variable
- type_T *imp_type;
- int imp_var_vals_idx; // index in sn_var_vals of "from"
-
- // for a function
- char_u *imp_funcname; // user func name (NOT allocated)
} imported_T;
-#define IMP_FLAGS_STAR 1 // using "import * as Name"
#define IMP_FLAGS_RELOAD 2 // script reloaded, OK to redefine
/*
@@ -4264,6 +4255,10 @@ typedef struct lval_S
char_u *ll_name_end; // end of variable name (can be NULL)
type_T *ll_type; // type of variable (can be NULL)
char_u *ll_exp_name; // NULL or expanded name in allocated memory.
+
+ scid_T ll_sid; // for an imported item: the script ID it was
+ // imported from; zero otherwise
+
typval_T *ll_tv; // Typeval of item being used. If "newkey"
// isn't NULL it's the Dict to which to add
// the item.