From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from gatech.edu (gatech.edu [130.207.244.244]) by werple.mira.net.au (8.6.12/8.6.9) with SMTP id UAA08950 for ; Thu, 29 Jun 1995 20:14:42 +1000 Received: from math (math.skiles.gatech.edu) by gatech.edu with SMTP id AA15570 (5.65c/Gatech-10.0-IDA for ); Thu, 29 Jun 1995 06:05:54 -0400 Received: by math (5.x/SMI-SVR4) id AA10706; Thu, 29 Jun 1995 06:02:18 -0400 Resent-Date: Thu, 29 Jun 95 11:02:31 +0100 Old-Return-Path: Message-Id: <9119.9506291002@pyro.swan.ac.uk> To: zsh-workers@math.gatech.edu (Zsh hackers list) Subject: Re: Z-Shell Frequently-Asked Questions (monthly posting) In-Reply-To: "hzoli@cs.elte.hu"'s message of "Wed, 28 Jun 95 20:16:12 BST." <9506281816.AA21228@turan.elte.hu> Date: Thu, 29 Jun 95 11:02:31 +0100 From: P.Stephenson@swansea.ac.uk X-Mts: smtp Resent-Message-Id: <"R6L2h.0.8d2.fedyl"@math> Resent-From: zsh-workers@math.gatech.edu X-Mailing-List: archive/latest/122 X-Loop: zsh-workers@math.gatech.edu Precedence: list Resent-Sender: zsh-workers-request@math.gatech.edu hzoli@cs.elte.hu wrote: > > B1) Differences from sh and ksh > > ... > > Command line substitutions, globbing etc.: > > Just one addition here: foo=* assignment assigns the list of files in the > current directory as an array to foo if there are at least two matches, or if > there is a single file in the directory, foo becames a scalar whose value is > the name of that file. Other Bourne shells does not glob the right hand side > of assignments. In my releases the default behaviour is to not glob here, but > this can be changed by setting the GLOB_ASSIGN option. I agree this is a little inconsistent. What about `foo=(*)', though? I use that kind of thing a lot, and it seems obvious to me that it should always do globbing --- at least, I tend to think of arguments of an array assignment behaving like command line arguments as far as word splitting is concerned. Perhaps it's not obvious to others. (I can do `set -A' but I like assignments to look like assignments.) > > Treatment of backslashes within backquotes is subtly different. > > I still do not know about such differences. I think they've now disappeared, though I don't know when that happened: certainly some pretty grotesque constructions now do the same in zsh as the other shells. I meant to delete this line. -- Peter Stephenson Tel: +44 1792 205678 extn. 4461 WWW: http://python.swan.ac.uk/~pypeters/ Fax: +44 1792 295324 Department of Physics, University of Wales, Swansea, Singleton Park, Swansea, SA2 8PP, U.K.