From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from math.gatech.edu (euclid.skiles.gatech.edu [130.207.146.50]) by werple.net.au (8.7/8.7.1) with SMTP id CAA08180 for ; Wed, 8 Nov 1995 02:09:01 +1100 (EST) Received: by math.gatech.edu (5.x/SMI-SVR4) id AA08107; Tue, 7 Nov 1995 09:54:44 -0500 Resent-Date: Tue, 7 Nov 1995 15:54:59 +0100 (MET) Old-Return-Path: From: pws@ifh.de (Peter William Stephenson) Message-Id: <9511071455.AA00926@sgi.ifh.de> Subject: unpleasant substitution bug To: zsh-workers@math.gatech.edu (Zsh hackers list) Date: Tue, 7 Nov 1995 15:54:59 +0100 (MET) X-Mailer: ELM [version 2.4 PL24] Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Resent-Message-Id: <"ArJiv.0.b-1.pCtdm"@euclid> Resent-From: zsh-workers@math.gatech.edu X-Mailing-List: archive/latest/545 X-Loop: zsh-workers@math.gatech.edu Precedence: list Resent-Sender: zsh-workers-request@math.gatech.edu I can't believe this bug's still there. The proper answer is probably to upgrade to Zoltan's substitution code as soon as possible. Until then, it's bad enough to need fixing anyway. % unset EMACS % print ${EMACS:-} } uurgh. *** Src/subst.c~ Tue Nov 7 04:43:21 1995 --- Src/subst.c Tue Nov 7 15:47:00 1995 *************** *** 903,913 **** if (!(flags & 0xf8)) flags |= 16; ! for (bct = 1; bct && *++s;) { if (*s == '{' || *s == Inbrace) bct++; else if (*s == '}' || *s == Outbrace) ! bct--; } if (*s) --- 903,914 ---- if (!(flags & 0xf8)) flags |= 16; ! for (bct = 1; *s; s++) { if (*s == '{' || *s == Inbrace) bct++; else if (*s == '}' || *s == Outbrace) ! if (!--bct) ! break; } if (*s) -- Peter Stephenson Tel: +49 33762 77366 WWW: http://www.ifh.de/~pws/ Fax: +49 33762 77330 Deutches Electronen-Synchrotron --- Institut fuer Hochenergiephysik Zeuthen DESY-IfH, 15735 Zeuthen, Germany.