fix: change did_emsg back to int

This commit is contained in:
zeertzjq
2022-10-10 23:46:34 +08:00
parent 249cb8345d
commit 2cc64dca92
2 changed files with 3 additions and 3 deletions

View File

@@ -199,7 +199,7 @@ EXTERN dict_T vimvardict; // Dictionary with v: variables
EXTERN dict_T globvardict; // Dictionary with g: variables EXTERN dict_T globvardict; // Dictionary with g: variables
/// g: value /// g: value
#define globvarht globvardict.dv_hashtab #define globvarht globvardict.dv_hashtab
EXTERN bool did_emsg; // set by emsg() when the message EXTERN int did_emsg; // set by emsg() when the message
// is displayed or thrown // is displayed or thrown
EXTERN bool called_vim_beep; // set if vim_beep() is called EXTERN bool called_vim_beep; // set if vim_beep() is called
EXTERN bool did_emsg_syntax; // did_emsg set because of a EXTERN bool did_emsg_syntax; // did_emsg set because of a

View File

@@ -658,7 +658,7 @@ static bool emsg_multiline(const char *s, bool multiline)
// interrupt message). // interrupt message).
if (cause_errthrow(s, severe, &ignore)) { if (cause_errthrow(s, severe, &ignore)) {
if (!ignore) { if (!ignore) {
did_emsg = true; did_emsg++;
} }
return true; return true;
} }
@@ -721,7 +721,7 @@ static bool emsg_multiline(const char *s, bool multiline)
} else { } else {
flush_buffers(FLUSH_MINIMAL); // flush internal buffers flush_buffers(FLUSH_MINIMAL); // flush internal buffers
} }
did_emsg = true; // flag for DoOneCmd() did_emsg++; // flag for DoOneCmd()
} }
emsg_on_display = true; // remember there is an error message emsg_on_display = true; // remember there is an error message