zsh-workers
 help / color / mirror / code / Atom feed
* unpleasant substitution bug
@ 1995-11-07 14:54 Peter William Stephenson
  0 siblings, 0 replies; only message in thread
From: Peter William Stephenson @ 1995-11-07 14:54 UTC (permalink / raw)
  To: Zsh hackers list

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 <pws@ifh.de>       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.


^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~1995-11-07 15:09 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
1995-11-07 14:54 unpleasant substitution bug Peter William Stephenson

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