zsh-workers
 help / color / mirror / code / Atom feed
From: Zefram <A.Main@dcs.warwick.ac.uk>
To: zsh-workers@math.gatech.edu (Z Shell workers mailing list)
Subject: Re: Completion quirks
Date: Sat, 15 Jul 1995 03:58:11 +0100 (BST)	[thread overview]
Message-ID: <711.199507150258@stone.dcs.warwick.ac.uk> (raw)
In-Reply-To: <no.id> from "zefram" at Jul 15, 95 03:19:33 am

-----BEGIN PGP SIGNED MESSAGE-----

I wrote:
>With hzoli10 I got this behaviour, and also with my own patched beta10
>(though starting with the correct match).  This problem is almost
>certainly a result of my completion list patches (which I can't test
>with every option, though I did give it a bit of a work out).  Plain
>beta10 for me misbehaved on the second completion, much in the way you
>describe, so I think it is safe to say that REC_EXACT is, for the
>moment, broken.  I'll see what I can do...

The patch below fixes both of the observed problems with REC_EXACT (one
of which was present in beta10 and probably earlier betas too).  The
problem of the completion prefix being inserted a second time was due
to a missing invalidatelist(), just like the previous case of this
problem (that Zoltan pointed out).  A quick grep for do_single
indicates that all calls to do_single() that should be followed by an
invalidatelist() now are.  The older problem is due to listambig being
set, and remaining set, when REC_EXACT is invoked, letting AUTO_MENU
start menu completion on the next tab when it shouldn't.  This is fixed
by moving the line that sets listambig.

 -zefram

      *** Src/zle_tricky.c.old	Sat Jul 15 03:40:02 1995
      --- Src/zle_tricky.c	Sat Jul 15 03:47:19 1995
      ***************
      *** 3187,3193 ****
        {
            int p = (usemenu || ispattern), atend = (cs == we);
        
      -     lastambig = 1;
            menucmp = 0;
        
            /* If we have to insert the first match, call do_single(). */
      --- 3187,3192 ----
      ***************
      *** 3194,3200 ****
      --- 3193,3201 ----
            if (shortest && shortl == 0 && isset(RECEXACT) &&
        	(usemenu == 0 || unset(AUTOMENU))) {
        	do_single(shortest);
      + 	invalidatelist();
            } else {
      + 	lastambig = 1;
        	if (p)
        	    /* Otherwise we have to do menu-completion... */
        	    do_ambig_menu();

-----BEGIN PGP SIGNATURE-----
Version: 2.6.i

iQBVAgUBMAcusmWJ8JfKi+e9AQGUpgH/d7kksV5LZ9LB3hCleFHVSPeDxzYQ8v08
Jx+xAYQs4r5QlhQeqxWL26bJyaeofm6+8PeS+M0/JkuUw8HM5ra/Ww==
=njj8
-----END PGP SIGNATURE-----


       reply	other threads:[~1995-07-15  2:59 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <no.id>
1995-07-15  2:58 ` Zefram [this message]
1995-07-15 18:54   ` Wayne Davison
1995-07-17 19:20     ` Zoltan Hidvegi
1995-07-15  0:49 Wayne Davison
1995-07-15  2:19 ` Zefram

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=711.199507150258@stone.dcs.warwick.ac.uk \
    --to=a.main@dcs.warwick.ac.uk \
    --cc=zsh-workers@math.gatech.edu \
    /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).