aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorKunMing Xie <qqzz014@gmail.com>2017-10-09 00:52:57 +0800
committerJustin M. Keyes <justinkz@gmail.com>2017-10-08 18:52:57 +0200
commit1663599bebd7bd360f116b003b9f572b01d7a8d8 (patch)
tree8fc211ed3aac1b33bcd55a7e11c3309baf097b1b /src
parente565fc229412dde1378db7d4dc80ed7ac9dfbcaf (diff)
downloadrneovim-1663599bebd7bd360f116b003b9f572b01d7a8d8.tar.gz
rneovim-1663599bebd7bd360f116b003b9f572b01d7a8d8.tar.bz2
rneovim-1663599bebd7bd360f116b003b9f572b01d7a8d8.zip
vim-patch:8.0.0164 (#7368)
Problem: Outdated and misplaced comments. Solution: Fix the comments. https://github.com/vim/vim/commit/caa55b65c204946d160c1b743c5f8f3b506dc4d3
Diffstat (limited to 'src')
-rw-r--r--src/nvim/charset.c2
-rw-r--r--src/nvim/eval.c2
-rw-r--r--src/nvim/getchar.c25
-rw-r--r--src/nvim/version.c2
4 files changed, 13 insertions, 18 deletions
diff --git a/src/nvim/charset.c b/src/nvim/charset.c
index 403ef65c4f..577fc13a31 100644
--- a/src/nvim/charset.c
+++ b/src/nvim/charset.c
@@ -762,7 +762,7 @@ bool vim_isIDc(int c)
}
/// Check that "c" is a keyword character:
-/// Letters and characters from 'iskeyword' option for current buffer.
+/// Letters and characters from 'iskeyword' option for the current buffer.
/// For multi-byte characters mb_get_class() is used (builtin rules).
///
/// @param c character to check
diff --git a/src/nvim/eval.c b/src/nvim/eval.c
index 86b99c2783..b2a0d9a767 100644
--- a/src/nvim/eval.c
+++ b/src/nvim/eval.c
@@ -17528,7 +17528,7 @@ static void f_winsaveview(typval_T *argvars, typval_T *rettv, FunPtr fptr)
tv_dict_add_nr(dict, S_LEN("skipcol"), (varnumber_T)curwin->w_skipcol);
}
-/// Writes list of strings to file
+/// Write "list" of strings to file "fd".
///
/// @param fp File to write to.
/// @param[in] list List to write.
diff --git a/src/nvim/getchar.c b/src/nvim/getchar.c
index f5949333bd..4f8a8528a0 100644
--- a/src/nvim/getchar.c
+++ b/src/nvim/getchar.c
@@ -868,20 +868,15 @@ int ins_typebuf(char_u *str, int noremap, int offset, int nottyped, bool silent)
addlen = (int)STRLEN(str);
- /*
- * Easy case: there is room in front of typebuf.tb_buf[typebuf.tb_off]
- */
if (offset == 0 && addlen <= typebuf.tb_off) {
+ // Easy case: there is room in front of typebuf.tb_buf[typebuf.tb_off]
typebuf.tb_off -= addlen;
memmove(typebuf.tb_buf + typebuf.tb_off, str, (size_t)addlen);
- }
- /*
- * Need to allocate a new buffer.
- * In typebuf.tb_buf there must always be room for 3 * MAXMAPLEN + 4
- * characters. We add some extra room to avoid having to allocate too
- * often.
- */
- else {
+ } else {
+ // Need to allocate a new buffer.
+ // In typebuf.tb_buf there must always be room for 3 * MAXMAPLEN + 4
+ // characters. We add some extra room to avoid having to allocate too
+ // often.
newoff = MAXMAPLEN + 4;
newlen = typebuf.tb_len + addlen + newoff + 4 * (MAXMAPLEN + 4);
if (newlen < 0) { /* string is getting too long */
@@ -1663,10 +1658,10 @@ static int vgetorpeek(int advance)
}
if (c != NUL && !got_int) {
if (advance) {
- /* KeyTyped = FALSE; When the command that stuffed something
- * was typed, behave like the stuffed command was typed.
- * needed for CTRL-W CTRl-] to open a fold, for example. */
- KeyStuffed = TRUE;
+ // KeyTyped = FALSE; When the command that stuffed something
+ // was typed, behave like the stuffed command was typed.
+ // needed for CTRL-W CTRL-] to open a fold, for example.
+ KeyStuffed = true;
}
if (typebuf.tb_no_abbr_cnt == 0)
typebuf.tb_no_abbr_cnt = 1; /* no abbreviations now */
diff --git a/src/nvim/version.c b/src/nvim/version.c
index 8015d7520d..11ae3f11b6 100644
--- a/src/nvim/version.c
+++ b/src/nvim/version.c
@@ -939,7 +939,7 @@ static const int included_patches[] = {
167,
// 166,
165,
- // 164,
+ 164,
// 163 NA
// 162 NA
// 161 NA