From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 22959 invoked from network); 26 Mar 2003 10:45:34 -0000 Received: from sunsite.dk (130.225.247.90) by ns1.primenet.com.au with SMTP; 26 Mar 2003 10:45:34 -0000 Received: (qmail 12185 invoked by alias); 26 Mar 2003 10:45:29 -0000 Mailing-List: contact zsh-workers-help@sunsite.dk; run by ezmlm Precedence: bulk X-No-Archive: yes X-Seq: 18388 Received: (qmail 12178 invoked from network); 26 Mar 2003 10:45:28 -0000 Received: from localhost (HELO sunsite.dk) (127.0.0.1) by localhost with SMTP; 26 Mar 2003 10:45:28 -0000 X-MessageWall-Score: 0 (sunsite.dk) Received: from [62.189.183.235] by sunsite.dk (MessageWall 1.0.8) with SMTP; 26 Mar 2003 10:45:28 -0000 Received: from exchange01.csr.com (unverified) by (Content Technologies SMTPRS 4.2.1) with ESMTP id for ; Wed, 26 Mar 2003 10:53:11 +0000 Received: from csr.com (tinky-winky.csr.com [192.168.144.127]) by exchange01.csr.com with SMTP (Microsoft Exchange Internet Mail Service Version 5.5.2650.21) id G0TVKJ3Q; Wed, 26 Mar 2003 10:30:29 -0000 To: zsh-workers@sunsite.dk Subject: Re: Disk-based or db-based associative array -- good or bad? In-reply-to: "William Park"'s message of "Tue, 25 Mar 2003 20:50:34 EST." <20030326015034.GA7771@node1.opengeometry.net> Date: Wed, 26 Mar 2003 10:31:08 +0000 Message-ID: <1279.1048674668@csr.com> From: Peter Stephenson William Park wrote: > I just wanted to ask shell experts here. Is disk-based associative > array a good thing to have for a shell? That is, reading and writing > like normal in-memory array, ie > typeset -A var > var[aa]='bb' > echo ${var[aa]} > except that 'aa':'bb' key:value will be written to and read from db file > (either Gdbm or Berkeley BD) on disk. As an add-on module this would be a very good thing to have. It would fit in well with existing modules such as zsh/parameter and zsh/mapfile. One problem at present is we don't have a way of associating a parameter with a particular implementation. I think something from ksh93 would do this. Otherwise we can define some `tie'-like syntax for typeset. -- Peter Stephenson Software Engineer CSR Ltd., Science Park, Milton Road, Cambridge, CB4 0WH, UK Tel: +44 (0)1223 692070 ********************************************************************** The information transmitted is intended only for the person or entity to which it is addressed and may contain confidential and/or privileged material. Any review, retransmission, dissemination or other use of, or taking of any action in reliance upon, this information by persons or entities other than the intended recipient is prohibited. If you received this in error, please contact the sender and delete the material from any computer. **********************************************************************