From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 24690 invoked by alias); 6 Jan 2010 13:55:24 -0000 Mailing-List: contact zsh-workers-help@zsh.org; run by ezmlm Precedence: bulk X-No-Archive: yes List-Id: Zsh Workers List List-Post: List-Help: X-Seq: 27573 Received: (qmail 24364 invoked from network); 6 Jan 2010 13:55:11 -0000 X-Spam-Checker-Version: SpamAssassin 3.2.5 (2008-06-10) on f.primenet.com.au X-Spam-Level: X-Spam-Status: No, score=-2.6 required=5.0 tests=BAYES_00 autolearn=ham version=3.2.5 Received-SPF: pass (ns1.primenet.com.au: SPF record at cis.strath.ac.uk designates 130.159.196.96 as permitted sender) Message-Id: From: Duncan Sinclair To: zsh-workers@zsh.org In-Reply-To: <20100105094829.613883ab@news01> Content-Type: text/plain; charset=WINDOWS-1252; format=flowed; delsp=yes Content-Transfer-Encoding: quoted-printable Mime-Version: 1.0 (Apple Message framework v936) Subject: Re: [PATCH] Removed arbitrary limitations on array accesses Date: Wed, 6 Jan 2010 13:42:03 +0000 References: <1262655497-21263-1-git-send-email-michael.a.hwang@gmail.com> <20100105094829.613883ab@news01> X-Mailer: Apple Mail (2.936) X-CIS-MailScanner-SpamCheck: authenticated, not scanned X-Scanned-By: MIMEDefang on 130.159.196.96 On 5 Jan 2010, at 9:48 am, Peter Stephenson wrote: > On Mon, 4 Jan 2010 20:38:17 -0500 > Michael Hwang wrote: >> This issue was brought up on IRC. It appears that while there is no =20= >> limit on >> how many array elements can be stored, there is a limit to how many =20= >> can be >> accessed. This patch removes these limits. > > Those have been there for a long time. I don't have any evidence that > they're doing a lot of good but we have had people creating positional > parameters with =3Dsomething and wondering why it uses a =20= > lot of > memory. I suppose this is similar. The arbitrary limit is not very > useful and also undocumented; most people wouldn't miss it if it =20 > wasn't > there, certainly. IIRC, the problem was that is you typed a big number at the zsh prompt =20= and hit tab, the shell would either hang for a long time or crash (out =20= of memory). % 99999999999 I reported this as a bug =96 the shell should not crash so easily. There is probably a way of preventing this problem though without =20 putting arbitrary limits on the size of array indices. --=20 Duncan Sinclair | {+44|0}141 548 3592 | cis.strath.ac.uk System Administrator Computer and Information Sciences University of Strathclyde The University of Strathclyde is a charitable body, registered in =20 Scotland, number SC015263.