Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
PATCH: 3.1.4: Off-by-an-order-of-magnitude in negated digit arguments
- X-seq: zsh-workers 4268
- From: "Bart Schaefer" <schaefer@xxxxxxxxxxxxxxxx>
- To: zsh-workers@xxxxxxxxxxxxxxx
- Subject: PATCH: 3.1.4: Off-by-an-order-of-magnitude in negated digit arguments
- Date: Wed, 5 Aug 1998 11:37:10 -0700
I only noticed this because of my earlier patch to pass the digit argument
as the first parameter to user-defined widgets.
Try using ESC - ESC 5 C-f in the line editor. You'll find that it moves
backwards 15 spaces, not 5 spaces. ESC - ESC 5 ESC 4 C-f moves backwards
154 spaces, ESC - ESC 5 ESC 4 ESC 3 backs up 1543 spaces, etc.
The problem is that negargument() should NOT set the MOD_TMULT flag. I've
scanned the other uses of MOD_TMULT and I don't think the following patch
has any bad side-effects.
Index: Src/Zle/zle_misc.c
===================================================================
*** zle_misc.c 1998/06/01 17:08:46 1.1.1.1
--- zle_misc.c 1998/08/05 18:30:20
***************
*** 456,462 ****
return;
}
zmod.tmult = -1;
- zmod.flags |= MOD_TMULT;
prefixflag = 1;
}
--- 456,461 ----
--
Bart Schaefer Brass Lantern Enterprises
http://www.well.com/user/barts http://www.brasslantern.com
Messages sorted by:
Reverse Date,
Date,
Thread,
Author