From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 1165 invoked from network); 22 Sep 2003 09:28:10 -0000 Received: from sunsite.dk (130.225.247.90) by ns1.primenet.com.au with SMTP; 22 Sep 2003 09:28:10 -0000 Received: (qmail 4962 invoked by alias); 22 Sep 2003 09:28:05 -0000 Mailing-List: contact zsh-workers-help@sunsite.dk; run by ezmlm Precedence: bulk X-No-Archive: yes X-Seq: 19109 Received: (qmail 4952 invoked from network); 22 Sep 2003 09:28:04 -0000 Received: from localhost (HELO sunsite.dk) (127.0.0.1) by localhost with SMTP; 22 Sep 2003 09:28:04 -0000 X-MessageWall-Score: 0 (sunsite.dk) Received: from [217.174.194.138] by sunsite.dk (MessageWall 1.0.8) with SMTP; 22 Sep 2003 9:28:4 -0000 Received: from DervishD.pleyades.net (212.Red-80-35-44.pooles.rima-tde.net [80.35.44.212]) by madrid10.amenworld.com (8.10.2/8.10.2) with ESMTP id h8M9S2816672; Mon, 22 Sep 2003 11:28:02 +0200 Received: from raul@pleyades.net by DervishD.pleyades.net with local (Exim MTA 2.05) id <1A1N2b-0000eg-00>; Mon, 22 Sep 2003 11:31:33 +0200 Date: Mon, 22 Sep 2003 11:31:33 +0200 From: DervishD To: Oliver Kiddle Cc: Zsh Subject: Re: Problem with an exported array Message-ID: <20030922093133.GA2518@DervishD> Mail-Followup-To: Oliver Kiddle , Zsh References: <20030922083017.GA1121@DervishD> <29185.1064221726@gmcs3.local> Mime-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: <29185.1064221726@gmcs3.local> User-Agent: Mutt/1.4i Organization: Pleyades User-Agent: Mutt/1.4i Hi Oliver :) * Oliver Kiddle dixit: > > then 'man' works OK. Am I doing something wrong or is just that > > arrays cannot be exported? BTW I'm using zsh 4.0.7 > Arrays cannot be exported. Oh :((( So I'm stuck with the ${= notation, I suppose. Or maybe I can use two variables, one scalar for programs that want PAGER in their environment, like man, and other for use interactively, when manually write '|$PAGER', which will be an array. I'll try to choose sensible names... BTW, is this noted in the manual? I've missed it if so. > Not so much a zsh limitation as a limitation in the way Unix stores > the environment. I was thinking about it: how the heck does zsh to store a specially formatted variable, like an array is, in the standard environment so the programs which use it doesn't get confused? > There are hacks which could allow us to represent arrays in it but not > in a way programs like man could be expected to understand. Obviously. > ksh (88 and 93) seem to export just the first element for an exported > array so you might argue we should do that. No, I won't ;)) I don't thing that storing just the first element is a good idea. If you declare an array is quite possible that you want all items ;). Thanks a lot for the answer :) Raúl Núñez de Arenas Coronado -- Linux Registered User 88736 http://www.pleyades.net & http://raul.pleyades.net/