patch 7.4.1897
Problem: Various typos, long lines and style mistakes.
Solution: Fix the typos, wrap lines, improve style.
diff --git a/src/INSTALL b/src/INSTALL
index 521d058..a827fa1 100644
--- a/src/INSTALL
+++ b/src/INSTALL
@@ -11,7 +11,7 @@
See INSTALLami.txt for Amiga
See INSTALLmac.txt for Macintosh
-See INSTALLpc.txt for PC (MS-DOS, Windows 95/98/NT/XP)
+See INSTALLpc.txt for PC (Windows 95/98/NT/XP/Vista/7/8/10)
See INSTALLvms.txt for VMS
See INSTALLx.txt for cross-compiling on Unix
See ../README_390.txt for OS/390 Unix
diff --git a/src/buffer.c b/src/buffer.c
index 0bbb1f4..ee28bc9 100644
--- a/src/buffer.c
+++ b/src/buffer.c
@@ -2516,7 +2516,7 @@
nr = curwin->w_alt_fnum;
for (buf = firstbuf; buf != NULL; buf = buf->b_next)
if (buf->b_fnum == nr)
- return (buf);
+ return buf;
return NULL;
}
diff --git a/src/config.aap.in b/src/config.aap.in
index 819276f..eebd036 100644
--- a/src/config.aap.in
+++ b/src/config.aap.in
@@ -75,9 +75,6 @@
RUBY_CFLAGS = @RUBY_CFLAGS@
RUBY_LIBS = @RUBY_LIBS@
-SNIFF_SRC = @SNIFF_SRC@
-SNIFF_OBJ = @SNIFF_OBJ@
-
AWK = @AWK@
STRIP = @STRIP@
diff --git a/src/ex_docmd.c b/src/ex_docmd.c
index e5de379..368c2e9 100644
--- a/src/ex_docmd.c
+++ b/src/ex_docmd.c
@@ -2139,7 +2139,8 @@
#endif
}
ea.cmd = skipwhite(ea.cmd);
- lnum = get_address(&ea, &ea.cmd, ea.addr_type, ea.skip, ea.addr_count == 0);
+ lnum = get_address(&ea, &ea.cmd, ea.addr_type, ea.skip,
+ ea.addr_count == 0);
if (ea.cmd == NULL) /* error detected */
goto doend;
if (lnum == MAXLNUM)
diff --git a/src/getchar.c b/src/getchar.c
index 56de094..03c7586 100644
--- a/src/getchar.c
+++ b/src/getchar.c
@@ -79,7 +79,7 @@
static int KeyNoremap = 0; /* remapping flags */
/*
- * variables used by vgetorpeek() and flush_buffers()
+ * Variables used by vgetorpeek() and flush_buffers().
*
* typebuf.tb_buf[] contains all characters that are not consumed yet.
* typebuf.tb_buf[typebuf.tb_off] is the first valid character.
diff --git a/src/if_mzsch.c b/src/if_mzsch.c
index 37cebc5..51b0352 100644
--- a/src/if_mzsch.c
+++ b/src/if_mzsch.c
@@ -2725,7 +2725,8 @@
* Adjust marks. Invalidate any which lie in the
* changed range, and move any in the remainder of the buffer.
*/
- mark_adjust((linenr_T)lo, (linenr_T)(hi - 1), (long)MAXLNUM, (long)extra);
+ mark_adjust((linenr_T)lo, (linenr_T)(hi - 1),
+ (long)MAXLNUM, (long)extra);
changed_lines((linenr_T)lo, 0, (linenr_T)hi, (long)extra);
if (buf->buf == curwin->w_buffer)
diff --git a/src/main.aap b/src/main.aap
index 3c91d39..452cd97 100644
--- a/src/main.aap
+++ b/src/main.aap
@@ -347,7 +347,6 @@
$PYTHON_SRC
$TCL_SRC
$RUBY_SRC
- $SNIFF_SRC
$WORKSHOP_SRC
Objects =
diff --git a/src/option.c b/src/option.c
index d048cec..b17fc28 100644
--- a/src/option.c
+++ b/src/option.c
@@ -1665,7 +1665,7 @@
{"keywordprg", "kp", P_STRING|P_EXPAND|P_VI_DEF|P_SECURE,
(char_u *)&p_kp, PV_KP,
{
-#if defined(MSWIN)
+#ifdef MSWIN
(char_u *)":help",
#else
# ifdef VMS
diff --git a/src/testdir/README.txt b/src/testdir/README.txt
index 052ccf5..534f05f 100644
--- a/src/testdir/README.txt
+++ b/src/testdir/README.txt
@@ -5,7 +5,7 @@
The numbered tests are older, we have switched to named tests.
-And then you can chose between a new style test, which is a Vim script, or an
+And then you can choose between a new style test, which is a Vim script, or an
old style test, which uses Normal mode commands. Use a new style test if you
can.
@@ -21,13 +21,14 @@
What you can use (see test_assert.vim for an example):
- Call assert_equal(), assert_true() and assert_false().
- Use try/catch to check for exceptions.
-- Use alloc_fail() to have memory allocation fail. This makes it possible to
+- Use alloc_fail() to have memory allocation fail. This makes it possible
to check memory allocation failures are handled gracefully. You need to
change the source code to add an ID to the allocation. Update LAST_ID_USED
above alloc_id() to the highest ID used.
- Use disable_char_avail_for_testing(1) if char_avail() must return FALSE for
a while. E.g. to trigger the CursorMovedI autocommand event.
See test_cursor_func.vim for an example
+- See the start of runtest.vim for more help.
TO ADD AN OLD STYLE TEST:
diff --git a/src/testdir/test_reltime.vim b/src/testdir/test_reltime.vim
index 2ef2fbb..adabf16 100644
--- a/src/testdir/test_reltime.vim
+++ b/src/testdir/test_reltime.vim
@@ -23,5 +23,4 @@
call assert_true(reltimestr(differs) != '0.0')
call assert_true(reltimefloat(differs) < 0.1)
call assert_true(reltimefloat(differs) > 0.0)
-
endfunc
diff --git a/src/testdir/test_tagjump.vim b/src/testdir/test_tagjump.vim
index d8a333f..97d86e6 100644
--- a/src/testdir/test_tagjump.vim
+++ b/src/testdir/test_tagjump.vim
@@ -6,4 +6,5 @@
call assert_fails('ptag does_not_exist_tag_name', 'E426')
set tagstack&vim
endfunc
+
" vim: sw=2 et
diff --git a/src/version.c b/src/version.c
index c6ebdc4..6e8b0c7 100644
--- a/src/version.c
+++ b/src/version.c
@@ -754,6 +754,8 @@
static int included_patches[] =
{ /* Add new patch number below this line */
/**/
+ 1897,
+/**/
1896,
/**/
1895,