zsh-workers
 help / color / mirror / code / Atom feed
From: Sven Wischnowsky <wischnow@informatik.hu-berlin.de>
To: zsh-workers@sunsite.auc.dk
Subject: Re: other _arguments problems
Date: Mon, 14 Feb 2000 11:51:28 +0100 (MET)	[thread overview]
Message-ID: <200002141051.LAA09961@beta.informatik.hu-berlin.de> (raw)
In-Reply-To: Tanaka Akira's message of 13 Feb 2000 12:48:21 +0900


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<TAB>
> no arguments
> 
> It should insert ` '.

A missing re-activation of the option we are on.

> is27e1u11% _tst () { _arguments '-x' ':arg:' }
> is27e1u11% tst -<TAB>
> 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


             reply	other threads:[~2000-02-14 10:51 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2000-02-14 10:51 Sven Wischnowsky [this message]
  -- strict thread matches above, loose matches on Subject: below --
2000-02-13  3:48 Tanaka Akira

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=200002141051.LAA09961@beta.informatik.hu-berlin.de \
    --to=wischnow@informatik.hu-berlin.de \
    --cc=zsh-workers@sunsite.auc.dk \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.vuxu.org/mirror/zsh/

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).