Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
Re: r problem
- X-seq: zsh-workers 15808
- From: Bart Schaefer <schaefer@xxxxxxxxxxxxxxxx>
- To: Zsh Workers <zsh-workers@xxxxxxxxxx>
- Subject: Re: r problem
- Date: Sat, 15 Sep 2001 04:49:27 +0000
- In-reply-to: <Pine.LNX.4.33L2.0109131734180.19446-100000@xxxxxxxxxxxxxxx>
- Mailing-list: contact zsh-workers-help@xxxxxxxxxx; run by ezmlm
- References: <Pine.LNX.4.33L2.0109131734180.19446-100000@xxxxxxxxxxxxxxx>
On Sep 13, 5:52pm, Wayne Davison wrote:
}
} One potential solution to this would be to change the history-line-drop
} code to lookup "r" in a function list and avoid dropping "r" (but not
} "builtin r") if we find it. I don't know the function code well enough
} to know if there is an inexpensive call that should_ignore_line() could
} call for this or not.
It's just a hash lookup:
if (shfunctab->getnode(shfunctab, "r")) {
/* It's a function */
}
As it would only be happening after the command name had already been
compared to (fc|history|r), I don't think it's prohibitively expensive,
though it's exactly what exec.c is going to be doing a few instructions
later.
--
Bart Schaefer Brass Lantern Enterprises
http://www.well.com/user/barts http://www.brasslantern.com
Zsh: http://www.zsh.org | PHPerl Project: http://phperl.sourceforge.net
Messages sorted by:
Reverse Date,
Date,
Thread,
Author