0
0
mirror of https://github.com/vim/vim.git synced 2025-09-23 03:43:49 -04:00

patch 8.2.4053: Vim9: autoload mechanism doesn't fully work yet

Problem:    Vim9: autoload mechanism doesn't fully work yet.
Solution:   Define functions and variables with their autoload name, add the
            prefix when calling a function, find the variable in the table of
            script variables.
This commit is contained in:
Bram Moolenaar
2022-01-10 18:08:00 +00:00
parent ee63031b57
commit fe2ef0b2cd
9 changed files with 139 additions and 52 deletions

View File

@@ -1864,7 +1864,9 @@ typedef struct
int sn_state; // SN_STATE_ values
char_u *sn_save_cpo; // 'cpo' value when :vim9script found
char sn_is_vimrc; // .vimrc file, do not restore 'cpo'
char sn_is_autoload; // "vim9script autoload"
// for "vim9script autoload" this is "dir#scriptname#"
char_u *sn_autoload_prefix;
# ifdef FEAT_PROFILE
int sn_prof_on; // TRUE when script is/was profiled