From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 12199 invoked from network); 15 Sep 1999 08:23:42 -0000 Received: from sunsite.auc.dk (130.225.51.30) by ns1.primenet.com.au with SMTP; 15 Sep 1999 08:23:42 -0000 Received: (qmail 8918 invoked by alias); 15 Sep 1999 08:23:37 -0000 Mailing-List: contact zsh-workers-help@sunsite.auc.dk; run by ezmlm Precedence: bulk X-No-Archive: yes X-Seq: 7834 Received: (qmail 8910 invoked from network); 15 Sep 1999 08:23:36 -0000 Message-Id: <9909150748.AA12360@ibmth.df.unipi.it> To: zsh-workers@sunsite.auc.dk (Zsh hackers list) Subject: Re: PATCH: 3.1.6-pws-4: backreferences In-Reply-To: "Peter Stephenson"'s message of "Tue, 14 Sep 1999 15:45:38 DFT." <9909141345.AA24591@ibmth.df.unipi.it> Date: Wed, 15 Sep 1999 09:48:30 +0200 From: Peter Stephenson Peter Stephenson wrote: > - Really stringy strings are now optimized during pattern compilation, not > just execution: if there is no remaining token after remnulargs(), normal > compilation is skipped and the string saved as it is. Oops. This was slightly overoptimised, removing the ability of stringy filename path segments to approximate or case-desensitize. (e.g. (#a1)tst/ac failed to match tst/ab). --- Src/pattern.c.pat2 Tue Sep 14 15:07:09 1999 +++ Src/pattern.c Wed Sep 15 09:35:12 1999 @@ -338,11 +338,12 @@ if (!(patflags & PAT_ANY)) { /* Look for a really pure string, with no tokens at all. */ - for (strp = exp; *strp && - (!(patflags & PAT_FILE) || *strp != '/') && !itok(*strp); - strp++) - ; - if (*strp && *strp != '/') { + if (!patglobflags) + for (strp = exp; *strp && + (!(patflags & PAT_FILE) || *strp != '/') && !itok(*strp); + strp++) + ; + if (!strp || (*strp && *strp != '/')) { /* No, do normal compilation. */ strp = NULL; if (patcompswitch(0, &flags) == 0) -- Peter Stephenson Tel: +39 050 844536 WWW: http://www.ifh.de/~pws/ Dipartimento di Fisica, Via Buonarroti 2, 56127 Pisa, Italy