docs: misc (#28609)

Closes https://github.com/neovim/neovim/issues/28484.
Closes https://github.com/neovim/neovim/issues/28719.

Co-authored-by: Chris <crwebb85@gmail.com>
Co-authored-by: Gregory Anders <greg@gpanders.com>
Co-authored-by: Jake B <16889000+jakethedev@users.noreply.github.com>
Co-authored-by: Jonathan Raines <jonathan.s.raines@gmail.com>
Co-authored-by: Yi Ming <ofseed@foxmail.com>
Co-authored-by: Zane Dufour <zane@znd4.me>
Co-authored-by: zeertzjq <zeertzjq@outlook.com>
This commit is contained in:
dundargoc
2024-05-15 01:18:33 +02:00
committed by GitHub
parent b83d5fabc6
commit 7acf39ddab
24 changed files with 48 additions and 57 deletions

View File

@@ -353,7 +353,7 @@ void check_cursor_col(win_T *win)
// Allow cursor past end-of-line when:
// - in Insert mode or restarting Insert mode
// - in Visual mode and 'selection' isn't "old"
// - 'virtualedit' is set */
// - 'virtualedit' is set
if ((State & MODE_INSERT) || restart_edit
|| (VIsual_active && *p_sel != 'o')
|| (cur_ve_flags & VE_ONEMORE)

View File

@@ -4082,7 +4082,7 @@ void separate_nextcmd(exarg_T *eap)
break;
}
} else if (
// Check for '"': start of comment or '|': next command */
// Check for '"': start of comment or '|': next command
// :@" does not start a comment!
// :redir @" doesn't either.
(*p == '"'

View File

@@ -443,7 +443,7 @@ int grid_line_puts(int col, const char *text, int textlen, int attr)
if (col + mbyte_cells > max_col) {
// Only 1 cell left, but character requires 2 cells:
// display a '>' in the last column to avoid wrapping. */
// display a '>' in the last column to avoid wrapping.
schar = schar_from_ascii('>');
mbyte_cells = 1;
}

View File

@@ -1963,7 +1963,7 @@ int syn_name2id_len(const char *name, size_t len)
return 0;
}
// Avoid using stricmp() too much, it's slow on some systems */
// Avoid using stricmp() too much, it's slow on some systems
// Avoid alloc()/free(), these are slow too.
vim_memcpy_up(name_u, name, len);
name_u[len] = '\0';

View File

@@ -1197,7 +1197,7 @@ static int cin_is_cpp_baseclass(cpp_baseclass_cache_T *cached)
s = line;
}
if (s == line) {
// don't recognize "case (foo):" as a baseclass */
// don't recognize "case (foo):" as a baseclass
if (cin_iscase(s, false)) {
break;
}

View File

@@ -1812,8 +1812,7 @@ int makemap(FILE *fd, buf_T *buf)
iemsg(_("E228: makemap: Illegal mode"));
return FAIL;
}
do {
// do this twice if c2 is set, 3 times with c3 */
do { // do this twice if c2 is set, 3 times with c3
// When outputting <> form, need to make sure that 'cpo'
// is set to the Vim default.
if (!did_cpo) {

View File

@@ -999,7 +999,7 @@ static void uniquefy_paths(garray_T *gap, char *pattern)
memmove(path, path_cutoff, strlen(path_cutoff) + 1);
} else {
// Here all files can be reached without path, so get shortest
// unique path. We start at the end of the path. */
// unique path. We start at the end of the path.
char *pathsep_p = path + len - 1;
while (find_previous_pathsep(path, &pathsep_p)) {
if (vim_regexec(&regmatch, pathsep_p + 1, 0)

View File

@@ -10555,7 +10555,7 @@ nfa_do_multibyte:
// NFA_END_COMPOSING is the ). Note that right now we are
// building the postfix form, not the NFA itself;
// a composing char could be: a, b, c, NFA_COMPOSING
// where 'b' and 'c' are chars with codes > 256. */
// where 'b' and 'c' are chars with codes > 256.
while (true) {
EMIT(c);
if (i > 0) {

View File

@@ -2460,7 +2460,7 @@ int current_search(int count, bool forward)
// beginning of the file (cursor might be on the search match)
// except when Visual mode is active, so that extending the visual
// selection works.
if (i == 1 && !result) { // not found, abort */
if (i == 1 && !result) { // not found, abort
curwin->w_cursor = orig_pos;
if (VIsual_active) {
VIsual = save_VIsual;
@@ -3677,9 +3677,8 @@ void find_pattern_in_path(char *ptr, Direction dir, size_t len, bool whole, bool
true) & kEqualFiles) {
if (type != CHECK_PATH
&& action == ACTION_SHOW_ALL && files[i].matched) {
msg_putchar('\n'); // cursor below last one */
if (!got_int) { // don't display if 'q' typed at "--more--"
// message
msg_putchar('\n'); // cursor below last one
if (!got_int) { // don't display if 'q' typed at "--more--" message
msg_home_replace_hl(new_fname);
msg_puts(_(" (includes previously listed match)"));
prev_fname = NULL;