diff options
author | Bram Moolenaar <Bram@vim.org> | 2020-01-26 15:56:19 +0100 |
---|---|---|
committer | Bram Moolenaar <Bram@vim.org> | 2020-01-26 15:56:19 +0100 |
commit | 8a7d6542b33e5d2b352262305c3bfdb2d14e1cf8 (patch) | |
tree | 8e5f241129a1c690ea81d697a72fb4c1704c0cb6 /src/main.c | |
parent | 1d9215b9aaa120b9d78fee49488556f73007ce78 (diff) | |
download | vim-git-8a7d6542b33e5d2b352262305c3bfdb2d14e1cf8.tar.gz |
patch 8.2.0149: maintaining a Vim9 branch separately is more workv8.2.0149
Problem: Maintaining a Vim9 branch separately is more work.
Solution: Merge the Vim9 script changes.
Diffstat (limited to 'src/main.c')
-rw-r--r-- | src/main.c | 37 |
1 files changed, 21 insertions, 16 deletions
diff --git a/src/main.c b/src/main.c index 117c2072e..68a419eaa 100644 --- a/src/main.c +++ b/src/main.c @@ -482,7 +482,7 @@ vim_main2(void) # else (char_u *)"plugin/**/*.vim", # endif - DIP_ALL | DIP_NOAFTER); + DIP_ALL | DIP_NOAFTER, NULL); TIME_MSG("loading plugins"); vim_free(rtp_copy); @@ -3169,7 +3169,7 @@ source_startup_scripts(mparm_T *parmp) */ if (parmp->evim_mode) { - (void)do_source((char_u *)EVIM_FILE, FALSE, DOSO_NONE); + (void)do_source((char_u *)EVIM_FILE, FALSE, DOSO_NONE, NULL); TIME_MSG("source evim file"); } @@ -3180,7 +3180,7 @@ source_startup_scripts(mparm_T *parmp) if (parmp->use_vimrc != NULL) { if (STRCMP(parmp->use_vimrc, "DEFAULTS") == 0) - do_source((char_u *)VIM_DEFAULTS_FILE, FALSE, DOSO_NONE); + do_source((char_u *)VIM_DEFAULTS_FILE, FALSE, DOSO_NONE, NULL); else if (STRCMP(parmp->use_vimrc, "NONE") == 0 || STRCMP(parmp->use_vimrc, "NORC") == 0) { @@ -3191,7 +3191,7 @@ source_startup_scripts(mparm_T *parmp) } else { - if (do_source(parmp->use_vimrc, FALSE, DOSO_NONE) != OK) + if (do_source(parmp->use_vimrc, FALSE, DOSO_NONE, NULL) != OK) semsg(_("E282: Cannot read from \"%s\""), parmp->use_vimrc); } } @@ -3209,10 +3209,11 @@ source_startup_scripts(mparm_T *parmp) * Get system wide defaults, if the file name is defined. */ #ifdef SYS_VIMRC_FILE - (void)do_source((char_u *)SYS_VIMRC_FILE, FALSE, DOSO_NONE); + (void)do_source((char_u *)SYS_VIMRC_FILE, FALSE, DOSO_NONE, NULL); #endif #ifdef MACOS_X - (void)do_source((char_u *)"$VIMRUNTIME/macmap.vim", FALSE, DOSO_NONE); + (void)do_source((char_u *)"$VIMRUNTIME/macmap.vim", FALSE, + DOSO_NONE, NULL); #endif /* @@ -3227,28 +3228,31 @@ source_startup_scripts(mparm_T *parmp) */ if (process_env((char_u *)"VIMINIT", TRUE) != OK) { - if (do_source((char_u *)USR_VIMRC_FILE, TRUE, DOSO_VIMRC) == FAIL + if (do_source((char_u *)USR_VIMRC_FILE, TRUE, + DOSO_VIMRC, NULL) == FAIL #ifdef USR_VIMRC_FILE2 && do_source((char_u *)USR_VIMRC_FILE2, TRUE, - DOSO_VIMRC) == FAIL + DOSO_VIMRC, NULL) == FAIL #endif #ifdef USR_VIMRC_FILE3 && do_source((char_u *)USR_VIMRC_FILE3, TRUE, - DOSO_VIMRC) == FAIL + DOSO_VIMRC, NULL) == FAIL #endif #ifdef USR_VIMRC_FILE4 && do_source((char_u *)USR_VIMRC_FILE4, TRUE, - DOSO_VIMRC) == FAIL + DOSO_VIMRC, NULL) == FAIL #endif && process_env((char_u *)"EXINIT", FALSE) == FAIL - && do_source((char_u *)USR_EXRC_FILE, FALSE, DOSO_NONE) == FAIL + && do_source((char_u *)USR_EXRC_FILE, FALSE, + DOSO_NONE, NULL) == FAIL #ifdef USR_EXRC_FILE2 - && do_source((char_u *)USR_EXRC_FILE2, FALSE, DOSO_NONE) == FAIL + && do_source((char_u *)USR_EXRC_FILE2, FALSE, + DOSO_NONE, NULL) == FAIL #endif && !has_dash_c_arg) { // When no .vimrc file was found: source defaults.vim. - do_source((char_u *)VIM_DEFAULTS_FILE, FALSE, DOSO_NONE); + do_source((char_u *)VIM_DEFAULTS_FILE, FALSE, DOSO_NONE, NULL); } } @@ -3285,7 +3289,7 @@ source_startup_scripts(mparm_T *parmp) (char_u *)VIMRC_FILE, FALSE, TRUE) != FPC_SAME #endif ) - i = do_source((char_u *)VIMRC_FILE, TRUE, DOSO_VIMRC); + i = do_source((char_u *)VIMRC_FILE, TRUE, DOSO_VIMRC, NULL); if (i == FAIL) { @@ -3303,7 +3307,8 @@ source_startup_scripts(mparm_T *parmp) (char_u *)EXRC_FILE, FALSE, TRUE) != FPC_SAME #endif ) - (void)do_source((char_u *)EXRC_FILE, FALSE, DOSO_NONE); + (void)do_source((char_u *)EXRC_FILE, FALSE, + DOSO_NONE, NULL); } } if (secure == 2) @@ -3334,7 +3339,7 @@ main_start_gui(void) #endif // NO_VIM_MAIN /* - * Get an environment variable, and execute it as Ex commands. + * Get an environment variable and execute it as Ex commands. * Returns FAIL if the environment variable was not executed, OK otherwise. */ int |