about summary refs log tree commit diff
diff options
context:
space:
mode:
authorMikael Magnusson <mikachu@gmail.com>2011-05-12 15:55:12 +0000
committerMikael Magnusson <mikachu@gmail.com>2011-05-12 15:55:12 +0000
commit1ac8412d6faf8d1d631a8cb366ca69aef97405bf (patch)
tree6f97e75a01f89d3e664fa6a81c7bad2188c6af56
parent3b4fcfe79708a4901a7d768cef72b5fbcdf31cd1 (diff)
downloadzsh-1ac8412d6faf8d1d631a8cb366ca69aef97405bf.tar.gz
zsh-1ac8412d6faf8d1d631a8cb366ca69aef97405bf.tar.xz
zsh-1ac8412d6faf8d1d631a8cb366ca69aef97405bf.zip
29208: make vimatchbracket more useful in emacs mode
-rw-r--r--ChangeLog7
-rw-r--r--Src/Zle/zle_move.c3
2 files changed, 9 insertions, 1 deletions
diff --git a/ChangeLog b/ChangeLog
index d672a6081..9abc510ec 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,8 @@
+2011-05-12  Mikael Magnusson <mikachu@gmail.com>
+
+	* 29208: Src/Zle/zle_move.c: make vimatchbracket check the
+	character left of the cursor when at the end of the line.
+
 2011-05-11  Mikael Magnusson <mikachu@gmail.com>
 
 	* 29206: Doc/Zsh/mod_complist.yo: fix formatting.
@@ -14655,5 +14660,5 @@
 
 *****************************************************
 * This is used by the shell to define $ZSH_PATCHLEVEL
-* $Revision: 1.5291 $
+* $Revision: 1.5292 $
 *****************************************************
diff --git a/Src/Zle/zle_move.c b/Src/Zle/zle_move.c
index 925f9c29f..0e940bc21 100644
--- a/Src/Zle/zle_move.c
+++ b/Src/Zle/zle_move.c
@@ -536,6 +536,9 @@ vimatchbracket(UNUSED(char **args))
     int ocs = zlecs, dir, ct;
     unsigned char oth, me;
 
+    if ((zlecs == zlell || zleline[zlecs] == '\n') && zlecs > 0)
+	DECCS();
+
   otog:
     if (zlecs == zlell || zleline[zlecs] == '\n') {
 	zlecs = ocs;