mirror of
https://github.com/neovim/neovim.git
synced 2025-09-28 22:18:33 +00:00
refactor(fold): style #19175
* refactor(fold): update comment formatting * refactor(fold): use post-increment/decrement * refactor(fold): reduce scope of local variables * refactor(fold): use booleans
This commit is contained in:
@@ -2341,7 +2341,7 @@ static char *do_one_cmd(char **cmdlinep, int flags, cstack_T *cstack, LineGetter
|
||||
do_return(&ea, TRUE, FALSE, NULL);
|
||||
}
|
||||
}
|
||||
need_rethrow = check_cstack = FALSE;
|
||||
need_rethrow = check_cstack = false;
|
||||
|
||||
doend:
|
||||
// can happen with zero line number
|
||||
|
529
src/nvim/fold.c
529
src/nvim/fold.c
File diff suppressed because it is too large
Load Diff
@@ -224,7 +224,7 @@ EXTERN dict_T vimvardict; // Dictionary with v: variables
|
||||
EXTERN dict_T globvardict; // Dictionary with g: variables
|
||||
/// g: value
|
||||
#define globvarht globvardict.dv_hashtab
|
||||
EXTERN int did_emsg; // set by emsg() when the message
|
||||
EXTERN bool did_emsg; // set by emsg() when the message
|
||||
// is displayed or thrown
|
||||
EXTERN bool called_vim_beep; // set if vim_beep() is called
|
||||
EXTERN bool did_emsg_syntax; // did_emsg set because of a
|
||||
@@ -274,11 +274,11 @@ EXTERN except_T *current_exception;
|
||||
|
||||
/// Set when a throw that cannot be handled in do_cmdline() must be propagated
|
||||
/// to the cstack of the previously called do_cmdline().
|
||||
EXTERN int need_rethrow INIT(= false);
|
||||
EXTERN bool need_rethrow INIT(= false);
|
||||
|
||||
/// Set when a ":finish" or ":return" that cannot be handled in do_cmdline()
|
||||
/// must be propagated to the cstack of the previously called do_cmdline().
|
||||
EXTERN int check_cstack INIT(= false);
|
||||
EXTERN bool check_cstack INIT(= false);
|
||||
|
||||
/// Number of nested try conditionals (across function calls and ":source"
|
||||
/// commands).
|
||||
@@ -725,8 +725,7 @@ EXTERN bool need_highlight_changed INIT(= true);
|
||||
EXTERN FILE *scriptout INIT(= NULL); ///< Stream to write script to.
|
||||
|
||||
// volatile because it is used in a signal handler.
|
||||
EXTERN volatile int got_int INIT(= false); // set to true when interrupt
|
||||
// signal occurred
|
||||
EXTERN bool got_int INIT(= false); // set to true when interrupt signal occurred
|
||||
EXTERN bool bangredo INIT(= false); // set to true with ! command
|
||||
EXTERN int searchcmdlen; // length of previous search cmd
|
||||
EXTERN int reg_do_extmatch INIT(= 0); // Used when compiling regexp:
|
||||
|
@@ -652,7 +652,7 @@ static bool emsg_multiline(const char *s, bool multiline)
|
||||
// interrupt message).
|
||||
if (cause_errthrow(s, severe, &ignore)) {
|
||||
if (!ignore) {
|
||||
did_emsg++;
|
||||
did_emsg = true;
|
||||
}
|
||||
return true;
|
||||
}
|
||||
@@ -717,7 +717,7 @@ static bool emsg_multiline(const char *s, bool multiline)
|
||||
} else {
|
||||
flush_buffers(FLUSH_MINIMAL); // flush internal buffers
|
||||
}
|
||||
did_emsg++; // flag for DoOneCmd()
|
||||
did_emsg = true; // flag for DoOneCmd()
|
||||
}
|
||||
|
||||
emsg_on_display = true; // remember there is an error message
|
||||
|
Reference in New Issue
Block a user