vis

a vi-like editor based on Plan 9's structural regular expressions

git clone https://9o.is/git/vis.git

commit 3366174fcf78afa8da1acb660446a2a9e1332a90
parent 7c427b2921128295fe46a10b3f3e8de51628d472
Author: Marc André Tanner <mat@brain-dump.org>
Date:   Tue, 21 Apr 2015 11:58:37 +0200

Handle failure of a movement gracefully

This for example fixes movements to unset marks.

Diffstat:
Mvis.c | 1+
1 file changed, 1 insertion(+), 0 deletions(-)

diff --git a/vis.c b/vis.c @@ -1160,6 +1160,7 @@ static void action_do(Action *a) { if (pos == EPOS) { c.range.start = start; c.range.end = start; + pos = start; } else { c.range.start = MIN(start, pos); c.range.end = MAX(start, pos);