mirror of
https://github.com/neovim/neovim.git
synced 2025-09-07 20:08:17 +00:00
vim-patch:8.1.2368: using old C style comments
Problem: Using old C style comments.
Solution: Use // comments where appropriate.
c667da5185
This commit is contained in:
@@ -308,8 +308,8 @@ int open_buffer(int read_stdin, exarg_T *eap, int flags)
|
|||||||
curbuf->b_flags |= BF_READERR;
|
curbuf->b_flags |= BF_READERR;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Need to update automatic folding. Do this before the autocommands,
|
// Need to update automatic folding. Do this before the autocommands,
|
||||||
* they may use the fold info. */
|
// they may use the fold info.
|
||||||
foldUpdateAll(curwin);
|
foldUpdateAll(curwin);
|
||||||
|
|
||||||
// need to set w_topline, unless some autocommand already did that.
|
// need to set w_topline, unless some autocommand already did that.
|
||||||
@@ -864,8 +864,8 @@ void goto_buffer(exarg_T *eap, int start, int dir, int count)
|
|||||||
swap_exists_action = SEA_NONE;
|
swap_exists_action = SEA_NONE;
|
||||||
swap_exists_did_quit = true;
|
swap_exists_did_quit = true;
|
||||||
|
|
||||||
/* Restore the error/interrupt/exception state if not discarded by a
|
// Restore the error/interrupt/exception state if not discarded by a
|
||||||
* new aborting error, interrupt, or uncaught exception. */
|
// new aborting error, interrupt, or uncaught exception.
|
||||||
leave_cleanup(&cs);
|
leave_cleanup(&cs);
|
||||||
} else {
|
} else {
|
||||||
handle_swap_exists(&old_curbuf);
|
handle_swap_exists(&old_curbuf);
|
||||||
@@ -920,8 +920,8 @@ void handle_swap_exists(bufref_T *old_curbuf)
|
|||||||
}
|
}
|
||||||
// If "old_curbuf" is NULL we are in big trouble here...
|
// If "old_curbuf" is NULL we are in big trouble here...
|
||||||
|
|
||||||
/* Restore the error/interrupt/exception state if not discarded by a
|
// Restore the error/interrupt/exception state if not discarded by a
|
||||||
* new aborting error, interrupt, or uncaught exception. */
|
// new aborting error, interrupt, or uncaught exception.
|
||||||
leave_cleanup(&cs);
|
leave_cleanup(&cs);
|
||||||
} else if (swap_exists_action == SEA_RECOVER) {
|
} else if (swap_exists_action == SEA_RECOVER) {
|
||||||
// Reset the error/interrupt/exception state here so that
|
// Reset the error/interrupt/exception state here so that
|
||||||
@@ -935,8 +935,8 @@ void handle_swap_exists(bufref_T *old_curbuf)
|
|||||||
cmdline_row = msg_row;
|
cmdline_row = msg_row;
|
||||||
do_modelines(0);
|
do_modelines(0);
|
||||||
|
|
||||||
/* Restore the error/interrupt/exception state if not discarded by a
|
// Restore the error/interrupt/exception state if not discarded by a
|
||||||
* new aborting error, interrupt, or uncaught exception. */
|
// new aborting error, interrupt, or uncaught exception.
|
||||||
leave_cleanup(&cs);
|
leave_cleanup(&cs);
|
||||||
}
|
}
|
||||||
swap_exists_action = SEA_NONE; // -V519
|
swap_exists_action = SEA_NONE; // -V519
|
||||||
@@ -1153,8 +1153,8 @@ int do_buffer(int action, int start, int dir, int count, int forceit)
|
|||||||
} else {
|
} else {
|
||||||
bp = NULL;
|
bp = NULL;
|
||||||
while (count > 0 || (!unload && !buf->b_p_bl && bp != buf)) {
|
while (count > 0 || (!unload && !buf->b_p_bl && bp != buf)) {
|
||||||
/* remember the buffer where we start, we come back there when all
|
// remember the buffer where we start, we come back there when all
|
||||||
* buffers are unlisted. */
|
// buffers are unlisted.
|
||||||
if (bp == NULL) {
|
if (bp == NULL) {
|
||||||
bp = buf;
|
bp = buf;
|
||||||
}
|
}
|
||||||
@@ -1205,8 +1205,8 @@ int do_buffer(int action, int start, int dir, int count, int forceit)
|
|||||||
bufref_T bufref;
|
bufref_T bufref;
|
||||||
set_bufref(&bufref, buf);
|
set_bufref(&bufref, buf);
|
||||||
|
|
||||||
/* When unloading or deleting a buffer that's already unloaded and
|
// When unloading or deleting a buffer that's already unloaded and
|
||||||
* unlisted: fail silently. */
|
// unlisted: fail silently.
|
||||||
if (action != DOBUF_WIPE && buf->b_ml.ml_mfp == NULL && !buf->b_p_bl) {
|
if (action != DOBUF_WIPE && buf->b_ml.ml_mfp == NULL && !buf->b_p_bl) {
|
||||||
return FAIL;
|
return FAIL;
|
||||||
}
|
}
|
||||||
@@ -1386,8 +1386,8 @@ int do_buffer(int action, int start, int dir, int count, int forceit)
|
|||||||
}
|
}
|
||||||
|
|
||||||
if (buf == NULL) {
|
if (buf == NULL) {
|
||||||
/* Autocommands must have wiped out all other buffers. Only option
|
// Autocommands must have wiped out all other buffers. Only option
|
||||||
* now is to make the current buffer empty. */
|
// now is to make the current buffer empty.
|
||||||
return empty_curbuf(false, forceit, action);
|
return empty_curbuf(false, forceit, action);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -1510,9 +1510,9 @@ void set_curbuf(buf_T *buf, int action)
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
/* An autocommand may have deleted "buf", already entered it (e.g., when
|
// An autocommand may have deleted "buf", already entered it (e.g., when
|
||||||
* it did ":bunload") or aborted the script processing!
|
// it did ":bunload") or aborted the script processing!
|
||||||
* If curwin->w_buffer is null, enter_buffer() will make it valid again */
|
// If curwin->w_buffer is null, enter_buffer() will make it valid again
|
||||||
if ((buf_valid(buf) && buf != curbuf
|
if ((buf_valid(buf) && buf != curbuf
|
||||||
&& !aborting()
|
&& !aborting()
|
||||||
) || curwin->w_buffer == NULL) {
|
) || curwin->w_buffer == NULL) {
|
||||||
@@ -2227,8 +2227,8 @@ int buflist_findpat(const char_u *pattern, const char_u *pattern_end, bool unlis
|
|||||||
&& (!diffmode || diff_mode_buf(buf))
|
&& (!diffmode || diff_mode_buf(buf))
|
||||||
&& buflist_match(®match, buf, false) != NULL) {
|
&& buflist_match(®match, buf, false) != NULL) {
|
||||||
if (curtab_only) {
|
if (curtab_only) {
|
||||||
/* Ignore the match if the buffer is not open in
|
// Ignore the match if the buffer is not open in
|
||||||
* the current tab. */
|
// the current tab.
|
||||||
bool found_window = false;
|
bool found_window = false;
|
||||||
FOR_ALL_WINDOWS_IN_TAB(wp, curtab) {
|
FOR_ALL_WINDOWS_IN_TAB(wp, curtab) {
|
||||||
if (wp->w_buffer == buf) {
|
if (wp->w_buffer == buf) {
|
||||||
@@ -5160,9 +5160,9 @@ void ex_buffer_all(exarg_T *eap)
|
|||||||
swap_exists_action = SEA_NONE;
|
swap_exists_action = SEA_NONE;
|
||||||
swap_exists_did_quit = true;
|
swap_exists_did_quit = true;
|
||||||
|
|
||||||
/* Restore the error/interrupt/exception state if not
|
// Restore the error/interrupt/exception state if not
|
||||||
* discarded by a new aborting error, interrupt, or uncaught
|
// discarded by a new aborting error, interrupt, or uncaught
|
||||||
* exception. */
|
// exception.
|
||||||
leave_cleanup(&cs);
|
leave_cleanup(&cs);
|
||||||
} else {
|
} else {
|
||||||
handle_swap_exists(NULL);
|
handle_swap_exists(NULL);
|
||||||
|
Reference in New Issue
Block a user