diff runtime/doc/pattern.txt @ 9286:64035abb986b

commit https://github.com/vim/vim/commit/c95a302a4c42ec8230473cd4a5e0064d0a143aa8 Author: Bram Moolenaar <Bram@vim.org> Date: Sun Jun 12 23:01:46 2016 +0200 Updated runtime files.
author Christian Brabandt <cb@256bit.org>
date Sun, 12 Jun 2016 23:15:06 +0200
parents 34c45ee4210d
children 01521953bdf1
line wrap: on
line diff
--- a/runtime/doc/pattern.txt
+++ b/runtime/doc/pattern.txt
@@ -1,4 +1,4 @@
-*pattern.txt*   For Vim version 7.4.  Last change: 2016 Apr 26
+*pattern.txt*   For Vim version 7.4.  Last change: 2016 Jun 08
 
 
 		  VIM REFERENCE MANUAL    by Bram Moolenaar
@@ -954,14 +954,18 @@ An ordinary atom can be:
 <	When 'hlsearch' is set and you move the cursor around and make changes
 	this will clearly show when the match is updated or not.
 	To match the text up to column 17: >
-		/.*\%17v
-<	Column 17 is included, because that's where the "\%17v" matches,
-	even though this is a |/zero-width| match.  Adding a dot to match the
-	next character has the same result: >
-		/.*\%17v.
+		/^.*\%17v
+<	Column 17 is not included, because this is a |/zero-width| match. To
+	include the column use: >
+		/^.*\%17v.
 <	This command does the same thing, but also matches when there is no
 	character in column 17: >
-		/.*\%<18v.
+		/^.*\%<18v.
+<	Note that without the "^" to anchor the match in the first column,
+	this will also highlight column 17: >
+		/.*\%17v
+<	Column 17 is highlighted by 'hlsearch' because there is another match
+	where ".*" matches zero characters.
 <
 
 Character classes: {not in Vi}