mirror of
				https://github.com/neovim/neovim.git
				synced 2025-10-26 12:27:24 +00:00 
			
		
		
		
	vim-patch:8.0.1726: older MSVC doesn't support declarations halfway a block
Problem:    Older MSVC doesn't support declarations halfway a block.
Solution:   Move the declaration back to the start of the block.
df2c774ded
			
			
This commit is contained in:
		| @@ -1934,8 +1934,9 @@ void do_wqall(exarg_T *eap) | |||||||
|   int error = 0; |   int error = 0; | ||||||
|   int save_forceit = eap->forceit; |   int save_forceit = eap->forceit; | ||||||
|  |  | ||||||
|   if (eap->cmdidx == CMD_xall || eap->cmdidx == CMD_wqall) |   if (eap->cmdidx == CMD_xall || eap->cmdidx == CMD_wqall) { | ||||||
|     exiting = TRUE; |     exiting = true; | ||||||
|  |   } | ||||||
|  |  | ||||||
|   FOR_ALL_BUFFERS(buf) { |   FOR_ALL_BUFFERS(buf) { | ||||||
|     if (!bufIsChanged(buf)) { |     if (!bufIsChanged(buf)) { | ||||||
|   | |||||||
| @@ -6018,7 +6018,7 @@ static void ex_highlight(exarg_T *eap) | |||||||
|  */ |  */ | ||||||
| void not_exiting(void) | void not_exiting(void) | ||||||
| { | { | ||||||
|   exiting = FALSE; |   exiting = false; | ||||||
| } | } | ||||||
|  |  | ||||||
| static bool before_quit_autocmds(win_T *wp, bool quit_all, int forceit) | static bool before_quit_autocmds(win_T *wp, bool quit_all, int forceit) | ||||||
|   | |||||||
| @@ -510,7 +510,7 @@ EXTERN int sc_col;              /* column for shown command */ | |||||||
| // First NO_SCREEN, then NO_BUFFERS, then 0 when startup finished. | // First NO_SCREEN, then NO_BUFFERS, then 0 when startup finished. | ||||||
| EXTERN int starting INIT(= NO_SCREEN); | EXTERN int starting INIT(= NO_SCREEN); | ||||||
| // true when planning to exit. Might keep running if there is a changed buffer. | // true when planning to exit. Might keep running if there is a changed buffer. | ||||||
| EXTERN int exiting INIT(= false); | EXTERN bool exiting INIT(= false); | ||||||
| // is stdin a terminal? | // is stdin a terminal? | ||||||
| EXTERN int stdin_isatty INIT(= true); | EXTERN int stdin_isatty INIT(= true); | ||||||
| // is stdout a terminal? | // is stdout a terminal? | ||||||
|   | |||||||
| @@ -584,9 +584,7 @@ int main(int argc, char **argv) | |||||||
| void getout(int exitval) | void getout(int exitval) | ||||||
|   FUNC_ATTR_NORETURN |   FUNC_ATTR_NORETURN | ||||||
| { | { | ||||||
|   tabpage_T   *tp, *next_tp; |   exiting = true; | ||||||
|  |  | ||||||
|   exiting = TRUE; |  | ||||||
|  |  | ||||||
|   /* When running in Ex mode an error causes us to exit with a non-zero exit |   /* When running in Ex mode an error causes us to exit with a non-zero exit | ||||||
|    * code.  POSIX requires this, although it's not 100% clear from the |    * code.  POSIX requires this, although it's not 100% clear from the | ||||||
| @@ -603,8 +601,10 @@ void getout(int exitval) | |||||||
|   hash_debug_results(); |   hash_debug_results(); | ||||||
|  |  | ||||||
|   if (get_vim_var_nr(VV_DYING) <= 1) { |   if (get_vim_var_nr(VV_DYING) <= 1) { | ||||||
|     /* Trigger BufWinLeave for all windows, but only once per buffer. */ |     const tabpage_T *next_tp; | ||||||
|     for (tp = first_tabpage; tp != NULL; tp = next_tp) { |  | ||||||
|  |     // Trigger BufWinLeave for all windows, but only once per buffer. | ||||||
|  |     for (const tabpage_T *tp = first_tabpage; tp != NULL; tp = next_tp) { | ||||||
|       next_tp = tp->tp_next; |       next_tp = tp->tp_next; | ||||||
|       FOR_ALL_WINDOWS_IN_TAB(wp, tp) { |       FOR_ALL_WINDOWS_IN_TAB(wp, tp) { | ||||||
|         if (wp->w_buffer == NULL) { |         if (wp->w_buffer == NULL) { | ||||||
|   | |||||||
		Reference in New Issue
	
	Block a user
	 Jan Edmund Lazo
					Jan Edmund Lazo