From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 3302 invoked from network); 14 Feb 2000 10:51:34 -0000 Received: from sunsite.auc.dk (130.225.51.30) by ns1.primenet.com.au with SMTP; 14 Feb 2000 10:51:34 -0000 Received: (qmail 9434 invoked by alias); 14 Feb 2000 10:51:29 -0000 Mailing-List: contact zsh-workers-help@sunsite.auc.dk; run by ezmlm Precedence: bulk X-No-Archive: yes X-Seq: 9713 Received: (qmail 9426 invoked from network); 14 Feb 2000 10:51:29 -0000 Date: Mon, 14 Feb 2000 11:51:28 +0100 (MET) Message-Id: <200002141051.LAA09961@beta.informatik.hu-berlin.de> From: Sven Wischnowsky To: zsh-workers@sunsite.auc.dk In-reply-to: Tanaka Akira's message of 13 Feb 2000 12:48:21 +0900 Subject: Re: other _arguments problems Tanaka Akira wrote: > I found two other _arguments problems when I wrote _psutils. > > Z(2):akr@is27e1u11% Src/zsh -f > is27e1u11% bindkey -e; autoload -U compinit; compinit -D; compdef _tst tst > is27e1u11% zstyle ':completion*:messages' format '%d' > is27e1u11% _tst () { _arguments '-x:arg:' } > is27e1u11% tst -x > no arguments > > It should insert ` '. A missing re-activation of the option we are on. > is27e1u11% _tst () { _arguments '-x' ':arg:' } > is27e1u11% tst - > arg > > It should insert `x '. A result of 9452 which has been fixed by other means in the meantime. Bye Sven diff -ru ../z.old/Completion/Base/_arguments Completion/Base/_arguments --- ../z.old/Completion/Base/_arguments Mon Feb 14 11:28:56 2000 +++ Completion/Base/_arguments Mon Feb 14 11:49:04 2000 @@ -254,7 +254,7 @@ fi fi - if [[ -z "$matched$mesg" ]] && _requested options && + if [[ -z "$matched" ]] && _requested options && { ! zstyle -t ":completion:${curcontext}:options" prefix-needed || [[ "$origpre" = [-+]* || ( -z "$aret$mesg" && nm -eq compstate[nmatches] ) ]] } ; then diff -ru ../z.old/Src/Zle/computil.c Src/Zle/computil.c --- ../z.old/Src/Zle/computil.c Mon Feb 14 11:29:26 2000 +++ Src/Zle/computil.c Mon Feb 14 11:41:44 2000 @@ -1261,6 +1261,7 @@ ca_laststate.ddef = ddef; ca_laststate.def = NULL; ca_laststate.opt = 1; + state.curopt->active = 1; } else { ca_laststate.doff = doff; ca_laststate.opt = 0; -- Sven Wischnowsky wischnow@informatik.hu-berlin.de