zsh-workers
 help / color / mirror / code / Atom feed
From: Sven Wischnowsky <wischnow@informatik.hu-berlin.de>
To: zsh-workers@sunsite.auc.dk
Subject: Re: Compadd churning on matching specs
Date: Tue, 25 Apr 2000 13:25:15 +0200 (MET DST)	[thread overview]
Message-ID: <200004251125.NAA04170@beta.informatik.hu-berlin.de> (raw)
In-Reply-To: Felix Rosencrantz's message of Tue, 25 Apr 2000 00:52:12 -0700 (PDT)


Felix Rosencrantz wrote:

> ...
> 
> With all the matching specifications that I provided and the ones
> _path_files provided, this causes match_str to chew for a while.  This
> seems wasteful, since we already know that the first part of the path is
> fully specified.  Would it be possible to just do matching on the last
> part of the path, where "function" should be added?

No. At least, not really. The `problem' is that match_str() does more
than just check if the match matches the stuff on the line. It also
builds the mystical cline lists which contain the information we need
when building the unambiguous string.

I always wanted to see if and how I could make matching faster... maybe
now that enough people have started using match specs it is the time
to try. I'll need some time for this, though, I'm hoping to be able to 
replace some of the matching attempts with strcmp() and splitting the
string into parts. Dunno how well this will work, though.


When using match specs, it is often a good idea to give an empty
string as the first value to the matcher-list style. As Peter said, it 
reduces the number of surprising match results, but it also makes the
first attempt faster for most of the common cases.

Bye
 Sven


--
Sven Wischnowsky                         wischnow@informatik.hu-berlin.de


             reply	other threads:[~2000-04-25 11:25 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2000-04-25 11:25 Sven Wischnowsky [this message]
  -- strict thread matches above, loose matches on Subject: below --
2000-04-25  7:52 Felix Rosencrantz

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=200004251125.NAA04170@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).