Zsh Mailing List Archive
Messages sorted by: Reverse Date, Date, Thread, Author

Re: _expand_alias does not expand aliases that contain an "!"



On Wed, 01 Oct 2014 15:06:41 +0100
Peter Stephenson <p.stephenson@xxxxxxxxxxx> wrote:
> On Wed, 1 Oct 2014 15:03:24 +0100
> Peter Stephenson <p.stephenson@xxxxxxxxxxx> wrote:
> > On possible fix would be to add a separate variable to remember the
> > original ISPECIAL bit for bangchar (which would be transferable if
> > bangchar became a different character) and restore it at this point if
> > this isn't the original setting up of typtab --- which is where the last
> > two tests really make sense.  So only the first two tests would remain
> > here in all cases.  That may seem a bit baroque given no other character
> > needs this, but it makes the code relatively insensitive to context.
> 
> Immediately after hitting "Send"(*), it occurred to me this just needs
> to be another bit in the typtab element, ISPECIAL_ORIGINALLY, though we
> still need to tell the code at this point whether or not this is the
> original case (easy enough).

Gag.  Sorry, no, that doesn't work if we change bangchar.  We'd have to
check if ISPECIAL_ORIGINALLY was set for the current bangchar before
changing and then pass that information back in, which far outweighs the
convenience.

pws



Messages sorted by: Reverse Date, Date, Thread, Author