zsh-workers
 help / color / mirror / code / Atom feed
From: hzoli@cs.elte.hu (Zoltan Hidvegi)
To: zsh-workers@math.gatech.edu (zsh-workers)
Subject: Re: Completion on =
Date: Wed, 19 Jul 1995 19:32:22 +0100 (MET DST)	[thread overview]
Message-ID: <9507191732.AA09066@turan.elte.hu> (raw)
In-Reply-To: <959.199507190735@stone.dcs.warwick.ac.uk> from "Zefram" at Jul 19, 95 08:35:30 am

Zefram wrote:

> The patch below fixes a couple of problems with filename completion on
> ~ and =.  Previously these characters were treated specially for
> completion even if quoted.

I did not test your changes yet, but I'm almost sure that they are not
correct.  Look at the first occurrance of docompletion() in zle_tricky.c.  The
current word is untokenized just before this call except those thing which are
within ${...} parameter expansion.  For some reason I do not remember clearly,
this is necessary (I think filename completion doesn't work well without it).
I'm sure that Sven could explain the problem more clearly.  The most confusing
thing is that docompletion() sometimes called with the tokenized string.  If
you examine makecomplist() (used to be docompletion()) more carefuly, you'll
see, that tokens and simple characters are handled similarily. E.g.

            if (*b != '^' && *b != Hat &&
                *b != '=' && *b != Equals &&
                *b != '~' && *b != Tilde)

I'm working now to fix several problems related to quoted characters in
completion strings.  I fixed most of the bugs here, and I think this bug can
also be fixed. A quoted tilde or = is always preceeded by a backslash, so in
this case line[wb] == '\\'.  We can use that to decide wether the tilde or =
is quoted or not.  But I guess it may be problematic when completing things
like \~foo$bar<TAB> since in this case (if I remember right) wb points after
the $.

Bye,
  Zoltan


  reply	other threads:[~1995-07-19 17:40 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
1995-07-19  7:35 Zefram
1995-07-19 18:32 ` Zoltan Hidvegi [this message]
1995-07-19 17:56   ` 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=9507191732.AA09066@turan.elte.hu \
    --to=hzoli@cs.elte.hu \
    --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).