From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 561 invoked from network); 12 Apr 2000 14:54:14 -0000 Received: from sunsite.auc.dk (130.225.51.30) by ns1.primenet.com.au with SMTP; 12 Apr 2000 14:54:14 -0000 Received: (qmail 5838 invoked by alias); 12 Apr 2000 14:53:56 -0000 Mailing-List: contact zsh-workers-help@sunsite.auc.dk; run by ezmlm Precedence: bulk X-No-Archive: yes X-Seq: 10702 Received: (qmail 5818 invoked from network); 12 Apr 2000 14:53:54 -0000 From: "Bart Schaefer" Message-Id: <1000412145336.ZM12301@candle.brasslantern.com> Date: Wed, 12 Apr 2000 14:53:35 +0000 In-Reply-To: <000201bfa47a$4c04c690$21c9ca95@mow.siemens.ru> Comments: In reply to "Andrej Borsenkow" "Should we backup this change? RE: Modifier substitutions." (Apr 12, 4:26pm) References: <000201bfa47a$4c04c690$21c9ca95@mow.siemens.ru> <200004121234.OAA09838@beta.informatik.hu-berlin.de> In-Reply-To: <200004121234.OAA09838@beta.informatik.hu-berlin.de> Comments: In reply to Sven Wischnowsky "Re: Should we backup this change? RE: Modifier substitutions." (Apr 12, 2:34pm) X-Mailer: Z-Mail (5.0.0 30July97) To: "Andrej Borsenkow" , "Zsh hackers list" , Sven Wischnowsky Subject: Re: Should we backup this change? RE: Modifier substitutions. MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii On Apr 12, 4:26pm, Andrej Borsenkow wrote: } Subject: Should we backup this change? RE: Modifier substitutions. } } There was no reply ... so I ask once more: should we backup this change? } } > -----Original Message----- } > > The `#' is being interpreted as an anchor at the head of the } > > string even } > > when buried inside $old. I have a feeling that wasn't my intention. } > > } > } > Erm ... it was done by Bart (do not have arcticle number handy) as a } > result of my question. On Apr 12, 2:34pm, Sven Wischnowsky wrote: } } I would be in favour of that. The possible confusion when } forgetting to check/quote the `#' and `%' at the beginning of } parameters used there is more important than the advantage, I think. The change went in in 6002. It was followed in 6003 by a change to allow a leading double backslash to escape the delimiter. So all you need to do is change uses of ${foo/$bar/...} into ${foo/\\$bar/...} to avoid the confusion. And without 6002, there's no way to build up an anchored pattern in a variable (which was Andrej's original complaint). Also, though I'm the last person to argue for keeping a change solely for compatibility, bash recognizes the same syntaxes. -- Bart Schaefer Brass Lantern Enterprises http://www.well.com/user/barts http://www.brasslantern.com