zsh-workers
 help / color / mirror / code / Atom feed
From: "Bart Schaefer" <schaefer@candle.brasslantern.com>
To: Peter Stephenson <pws@csr.com>,
	zsh-workers@sunsite.dk (Zsh hackers list)
Subject: Re: order of processing in brace expansion
Date: Sat, 28 Apr 2001 06:05:04 +0000	[thread overview]
Message-ID: <1010428060505.ZM29936@candle.brasslantern.com> (raw)
In-Reply-To: <Tc0a88d01532d9494fe@mailsweeper01.cambridgesiliconradio.com>

On Apr 27,  7:09pm, Peter Stephenson wrote:
} Subject: Re: order of processing in brace expansion
}
} I would expect what you expect: the expression is interpreted the same as
} a{b,c}d.  Unfortunately it isn't.  The reason seems to be that the comma
} doesn't get turned back into a token.  If we want to fix this, the
} following patch will do it.

The only issue, I think, is that comma is not a token unless it is inside
braces, and we don't know at time of expanding $~foo that the surrounding
expression is eligible for brace expansion.  A tokenized comma does still
match an "ordinary" comma during file globbing, but does that mean that it
always matches an ordinary comma?

If tokenizing when it's not necessary doesn't hurt anything, then I think
we should fix the bug.  ("make check" does pass with the patch applied.)

-- 
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   


  reply	other threads:[~2001-04-28  6:05 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2001-04-27 17:31 Allan Poindexter
2001-04-27 18:09 ` Peter Stephenson
2001-04-28  6:05   ` Bart Schaefer [this message]
2001-04-28 18:17     ` Bart Schaefer
2001-05-02  9:50     ` Peter Stephenson
2001-05-02 14:59       ` Bart Schaefer
2001-05-02 15:28         ` Peter Stephenson
2001-05-02 16:30           ` Bart Schaefer
2001-05-09  9:06             ` Peter Stephenson
2001-05-11 16:57               ` Allan Poindexter
2001-05-11 19:22             ` Allan Poindexter
2001-05-11 20:09               ` Bart Schaefer

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=1010428060505.ZM29936@candle.brasslantern.com \
    --to=schaefer@candle.brasslantern.com \
    --cc=pws@csr.com \
    --cc=zsh-workers@sunsite.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).