From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from euclid.skiles.gatech.edu (list@euclid.skiles.gatech.edu [130.207.146.50]) by melb.werple.net.au (8.7.5/8.7.3/2) with ESMTP id CAA24558 for ; Sat, 22 Jun 1996 02:11:13 +1000 (EST) Received: (from list@localhost) by euclid.skiles.gatech.edu (8.7.3/8.7.3) id LAA02759; Fri, 21 Jun 1996 11:42:24 -0400 (EDT) Resent-Date: Fri, 21 Jun 1996 11:42:24 -0400 (EDT) From: Ray_Van_Tassle-CRV004@email.mot.com Date: 21 Jun 96 10:26:27 -0500 To: hzoli@cs.elte.hu (Receipt Notification Requested), rayvt@dd201.comm.mot.com (Receipt Notification Requested) Cc: zsh-workers@math.gatech.edu (Receipt Notification Requested) Subject: RE: Bug in filename expansion Message-Id: <"Macintosh */PRMD=MOT/ADMD=MOT/C=US/"@MHS> Resent-Message-ID: <"n4vQA1.0.1h.WBion"@euclid> Resent-From: zsh-workers@math.gatech.edu X-Mailing-List: archive/latest/1413 X-Loop: zsh-workers@math.gatech.edu Precedence: list Resent-Sender: zsh-workers-request@math.gatech.edu [[ example deleted ]] > No, it isn't wrong. ^pattern matches if pattern does not match. You should > use groupping. > > zz^(a|b)yy is the same as zz^((a|b)yy) and zz(^(a|b))yy is what you want. > > Zoltan > No, that doesn't work either. Also, if my 1st attempt ("zz^(a|b)yy") is incorrect, this is a surprise, and it should probably be mentioned in the documentation. Or maybe the precedence of "^" changed ? If there isn't a bug here (and I think there is), then we need some further examples of "how to do it". Also.... how can I do a parenthisised group at the *end* of a pattern? It thinks that this is a "list of qualifiers". Here's my trial script & output: setopt verbose touch zzayy touch zzbyy touch zzxyy ls zz* zzayy zzbyy zzxyy #next works--shows a & b ls zz(a|b)yy zzayy zzbyy #next doesn't work--should show x ls zz^(a|b)yy ./try: no match [9] # zoltan says the above means the same as next ls zz(^(a|b)yy) ./try: no match [11] # zoltan says this will show x. but it doesn't ls zz(^(a|b))yy ./try: no match [13] unsetopt verbose