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 coral.primenet.com.au (8.7.5/8.7.3) with ESMTP id CAA02498 for ; Wed, 2 Oct 1996 02:03:00 +1000 (EST) Received: (from list@localhost) by euclid.skiles.gatech.edu (8.7.3/8.7.3) id LAA03340; Tue, 1 Oct 1996 11:23:24 -0400 (EDT) Resent-Date: Tue, 1 Oct 1996 11:23:24 -0400 (EDT) Message-Id: <199610011522.RAA02255@sgi.ifh.de> X-Authentication-Warning: sgi.ifh.de: Host pws@localhost didn't use HELO protocol To: peta@cim.mcgill.ca, zsh-workers@math.gatech.edu (Zsh hackers list) Subject: Re: Old 'cd ......' function broken. In-reply-to: "peta@cim.mcgill.ca"'s message of "Mon, 30 Sep 1996 15:57:34 MET." <199610011450.KAA15883@Pontryagin.McRCIM.McGill.EDU> Date: Tue, 01 Oct 1996 17:22:00 +0200 From: Peter Stephenson Resent-Message-ID: <"E7Jam3.0.6q.iTJKo"@euclid> Resent-From: zsh-workers@math.gatech.edu X-Mailing-List: archive/latest/2181 X-Loop: zsh-workers@math.gatech.edu Precedence: list Resent-Sender: zsh-workers-request@math.gatech.edu peta@cim.mcgill.ca wrote: > I got this from the zsh mailing list a while ago. It used to work > but no more (zsh-3.0.0). It doesnt like ${(r:(${#1}-1)*3-1::../:)b} It looks like the expression after the first : isn't being interpreted as a mathematical expression for evaluation any more. Somebody will know if this is a feature, otherwise it's a bug. You can get away with: eval "a=\${(r:$(((${#1}-1)*3-1))::../:)b}" which evaluates the expression first. -- 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.