Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:13624 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 88862 invoked by uid 1010); 30 Oct 2004 02:44:49 -0000 Delivered-To: ezmlm-scan-internals@lists.php.net Delivered-To: ezmlm-internals@lists.php.net Received: (qmail 88838 invoked from network); 30 Oct 2004 02:44:48 -0000 Received: from unknown (HELO air638.startdedicated.com) (69.64.38.41) by pb1.pair.com with SMTP; 30 Oct 2004 02:44:48 -0000 Received: from localhost (localhost.localdomain [127.0.0.1]) by air638.startdedicated.com (Postfix) with ESMTP id B7D04294344; Fri, 29 Oct 2004 21:39:52 -0500 (CDT) Received: from air638.startdedicated.com ([127.0.0.1]) by localhost (air638.startdedicated.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 20280-05; Fri, 29 Oct 2004 21:39:52 -0500 (CDT) Received: from [192.168.11.4] (66-65-38-153.nyc.rr.com [66.65.38.153]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by air638.startdedicated.com (Postfix) with ESMTP id 65AEA294341; Fri, 29 Oct 2004 21:39:52 -0500 (CDT) Message-ID: <4183001D.20609@chiaraquartet.net> Date: Fri, 29 Oct 2004 22:44:45 -0400 User-Agent: Mozilla Thunderbird 0.8 (Windows/20040913) X-Accept-Language: en-us, en MIME-Version: 1.0 To: Derick Rethans Cc: internals@lists.php.net References: <418294D9.4070700@prohost.org> <20041029193421.9557.qmail@pb1.pair.com> In-Reply-To: Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Virus-Scanned: by amavisd-new at bluga.net Subject: Re: [PHP-DEV] Re: Negative string offset support From: greg@chiaraquartet.net (Greg Beaver) Derick Rethans wrote: > On Fri, 29 Oct 2004, Greg Beaver wrote: > > >>Ilia Alshanetsky wrote: >> >>>I am wondering what are people's opinions on adding support for negative >>>string offsets that could be used to access data from the end of a string. >>> >>>Ex. $a = "123"; echo $a[-1]; // would print 3 >>> >>>I don't think we should do this for arrays, since -1 and similar are >>>valid array keys, which means adding this support for arrays would break >>>BC. >> >>I need this, +1 > > > How can you *need* this, you can use substr() just fine. I don't *need* PHP either. any other questions? Greg