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

Re: Allow slash in alternation patterns in limited cases?



On Mon, 11 Apr 2016 15:45:02 +0200
Mikael Magnusson <mikachu@xxxxxxxxx> wrote:
> On Mon, Apr 11, 2016 at 2:31 PM, Peter Stephenson
> <p.stephenson@xxxxxxxxxxx> wrote:
> > No, expressions like (foo|bar) are *only* handled by the pattern
> > matcher.  The scanner's sole responsibility is to tell the pattern
> > matcher whether or not it should stop if it sees a "/".
> 
> Ah, that explains it :). Thanks.

To be unhelpfully pedantic... actually, there's one exception, which is
that (.../) is handled specially so you can stick # or ## after it.
That's a special case in parsecomplist(), which looks a little like
what you're trying to do.

pws



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