Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
Re: PATCH: various minor fixes
- X-seq: zsh-workers 13868
- From: Sven Wischnowsky <wischnow@xxxxxxxxxxxxxxxxxxxxxxx>
- To: zsh-workers@xxxxxxxxxx
- Subject: Re: PATCH: various minor fixes
- Date: Mon, 2 Apr 2001 11:03:57 +0200 (MET DST)
- In-reply-to: Oliver Kiddle's message of Sun, 01 Apr 2001 16:13:19 +0100
- Mailing-list: contact zsh-workers-help@xxxxxxxxxx; run by ezmlm
Oliver Kiddle wrote:
> ...
>
> In the process, I noticed a bug with the -S option to _arguments: bzip2
> --<tab> now says 'no more arguments' where I would expect it to complete
> long options. _arguments -S should look for '--' as a complete, finished
> word.
Exactly. Hance easy to fix.
> Also, gzip -<tab> seems to move the cursor back over the minus.
This was yet another cursor-positioning bug caused by match specs. I
copied the wrong test in join_clines().
Bye
Sven
Index: Src/Zle/compmatch.c
===================================================================
RCS file: /cvsroot/zsh/zsh/Src/Zle/compmatch.c,v
retrieving revision 1.33
diff -u -r1.33 compmatch.c
--- Src/Zle/compmatch.c 2001/03/06 11:31:21 1.33
+++ Src/Zle/compmatch.c 2001/04/02 09:02:15
@@ -2076,7 +2076,8 @@
if ((diff = sub_join(o, n, tn, 0))) {
o->flags = (o->flags & ~CLF_MISS) | of;
- if (po) {
+ if (po && po->prefix &&
+ cmp_anchors(o, po, 0)) {
po->flags |= CLF_MISS;
po->max += diff;
}
Index: Src/Zle/computil.c
===================================================================
RCS file: /cvsroot/zsh/zsh/Src/Zle/computil.c,v
retrieving revision 1.46
diff -u -r1.46 computil.c
--- Src/Zle/computil.c 2001/03/26 10:02:26 1.46
+++ Src/Zle/computil.c 2001/04/02 09:02:16
@@ -1316,7 +1316,7 @@
doff = state.singles = arglast = 0;
if (ca_inactive(d, argxor, cur, 0) ||
- ((d->flags & CDF_SEP) && !strcmp(line, "--"))) {
+ ((d->flags & CDF_SEP) && cur != compcurrent && !strcmp(line, "--"))) {
if (ca_inactive(d, NULL, cur, 1))
return 1;
continue;
--
Sven Wischnowsky wischnow@xxxxxxxxxxxxxxxxxxxxxxx
Messages sorted by:
Reverse Date,
Date,
Thread,
Author